Advertisement |
Is it possible to switch back to the previous interface in the "0.3.x" versions of the extension?
Yes, the previous interface is still available within the package. Right-click the action button and select the old interface from the context menu to access it. However, note that as features are gradually ported to the new interface, the old one may eventually be deprecated. The new interface is designed to be more user-friendly and intuitive. For now, you can use both interfaces at the same time. You can open one interface and switch to the other by right-clicking on the action button.
recommended The "HexDump - Hex Viewer" extension for Chrome, Edge, and Firefox browsers
The "HexDump - Hex Viewer" extension provides a customizable tool for examining files in hexadecimal and binary formats, aiding tasks like file type identification using majic numbers and binary comparison. Read more here.
What is the "SQLite Manager" extension and how does it work?
The "SQLite Manager" extension is a user-friendly SQLite application that operates directly within your browser, requiring no native components. Its interface consists of two main blocks: the computational region and the tools area. The computational section stores the history of all executed SQL statements on the databases, while the tools area houses various commands.
In version "0.3.x," the extension offers keyboard shortcuts for almost all the commands in the tools area. You can view the instructions by hovering the mouse over the buttons. You can create a new database using the "New" button or drag and drop an existing SQL database into the interface to get started. The extension always displays the currently active database on the right side of the tools area. Each SQL statement you enter is executed on the active database, so make sure to select the correct database before running them.
Executing an SQLite statement is as simple as pressing the "Enter" key after writing the query. To manage your workspace effectively, you can clear the entire computational region using the "Clear" button or remove a single block using the "Close" button (located on the right side of the editor area). Commands related to a specific block are only displayed when the editor is focused to prevent interface cluttering.
Furthermore, the extension comes with a sample database, providing a convenient option for experimenting with a pre-existing database without going through additional setup.
Why doesn't the extension execute my statement when I press the "Enter" key?
The "Enter" key is reserved to execute the SQLite statement. Use the Shift + Enter keys to move to a new line.
What are the meanings of the numbers displayed around the editor area?
The "DB #" label on the left indicates that the current box's execution is associated with the database numbered "#". On the top right, the label "#n" shows the total count of executions across all databases. This count is used for importing data (not yet available on the new interface).
To execute a statement on a specific database, choose a database from the tools section then press the "Enter" key. This will execute the current statement in the editor on the selected database, and the "DB #" label will be updated to reflect the new association.
What is the most straightforward method to insert multiple rows into a table?
To insert multiple rows into an SQLite table, ensure that you have selected the target database. Next, write all the records in a comma-separated CSV format, and then drag and drop the CSV file into the interface. The extension will prompt you for the importing statement. In the importing statement, use "?" as placeholders for the parameters that need to be imported from the CSV database.
For example, if you want to import "column1" and "column2" from a two-column CSV database into a table named "MyTable," drop the CSV file and use the SQLite importing statement:
INSERT INTO MyTable (column1, column2) VALUES(?, ?)
The extension will display a notification showing the total number of records that have been imported.
How can I export an output table from the "SQLite Manager" extension?
Follow these steps:
Additionally, you can use the exported CSV database to import data into another SQLite database by selecting the new database and dropping it into the interface.
How can I visualize a table in the "SQLite Manager" extension?
Select the columns that you want to visualize. Press the "Plot" button to generate a chart with the rows plotted against the first selected row. If you wish to have the extension generate the "x" axis for you instead of using the first row, hold down the Shift key while clicking the "Plot" button. Keep in mind that the extension creates one plot for each selected row. If you prefer to use columns for plotting (each column versus the first column or the generated "x" axis), press the Ctrl or Command key while clicking the "Plot" button. You can combine the Ctrl key with Shift or the Command key with Shift to plot columns against the generated "x" axis.
Is there a way to have the "SQLite Manager" extension assist in writing SQLite statements, considering they can be challenging to remember?
The extension incorporates a comprehensive editor with snippet and autocomplete functionalities starting from version 0.3.0. When writing a statement, begin typing a part of the query, and a list of relevant snippets will be presented. You can choose the desired snippet from the list, making the statement-writing process more efficient.
Moreover, this editor supports keyboard shortcuts similar to those found in the SublimeText editor. For example, you can use Ctrl + D or Command + D to select a word, and Ctrl + L or Command + L to select an entire line. These shortcuts can further enhance your coding experience and streamline the statement writing process.
[Version 0.2.x] What is the "SQLite Manager" extension and how does it work?
The primary goal of this extension is to streamline SQLite database access, manipulation, and storage. Additionally, it provides efficient tools for visualizing database rows and columns. Moreover, you can import tables or specific parts of tables as matrices into the mathematical environment, enabling you to manipulate the data effortlessly.
What's new in this version?
Please check the Logs section.
[Version 0.2.x] How can I use this tool?
To use this tool efficiently, follow these steps:
new("database-name.sqlite")
in the command-line text box and press Enter.CREATE TABLE hello (name char, x int, y int);
command. Paste the command and press Enter; all the commands are listed for easy access and rerunning if necessary.INSERT INTO hello VALUES ("p1", 0, 0);
INSERT INTO hello VALUES ("p2", 1, 1);
INSERT INTO hello VALUES ("p3", 3, 3);
INSERT INTO hello VALUES ("p4", 4, 2);
INSERT INTO hello VALUES ("p5", 5, 4);
INSERT INTO hello VALUES ("p6", 8, 10);
INSERT INTO hello VALUES ("p7", 10, 120);
INSERT INTO hello VALUES ("p8", 11, 0);
To save the points to the table, press the Enter key. Next, you can verify that the data are indeed inserted into the table by executing the SELECT * FROM hello
statement. This query will provide us with a table containing all the points. Once we have the data, we can proceed to plot it. For plotting to work, we need to import the table into the "math.js" environment. Essentially, any commands that are not valid SQLite commands will be interpreted as "math.js" commands. For instance, you can multiply two numbers using the 1 + 2
command or create an array with the following command:a = [1,2,3];
b = [1:10];
c = a * 2;
This environment offers a convenient way to import our table.
By using the SQLite command SELECT * FROM hello | import as myVar
, we can easily port the table into this environment. "myVar" becomes a variable that holds the entire table.
You can also use the SELECT x, y FROM hello LIMIT 3 | import as mySecondVar
command for importing a section of the table.
Now that we have our table in the "math.js" environment as a matrix, let's plot it. We are going to use the built-in "plot" command, which requires one or two one-dimensional arrays. If a single-dimension array is passed, it is considered as the values in the y-direction, and the x-direction points are generated automatically.
To extract one-dimensional arrays from a column of the matrix, usemyVar[:,1]
. Similarly, to extract a one-dimensional array from a row of the matrix, use myVar[1,:]
, where "1" represents the one-based row number. For our example, since x and y arrays are located in the columns, we retrieve them as follows: x = myVar[:,2]; y = myVar[:, 3];
We are ready to plot with plot(x, y)
command! Note that at this time, plot function needs to be run in a new section to see the actual output.[Version 0.2.x] How powerful this "math.js" library is and where can I find its documentation?
The "math.js" library is one of the most powerful math libraries for interactive JavaScript applications. To learn more about its functionalities and syntaxes, you can visit the http://mathjs.org/ website. There, you will find comprehensive documentation and information about the library.
[Version 0.2.x] Can I save an in-memory database for future use?
You can achieve this by typing the command download(db-id)
in the command-line interface. Here, "db-id" represents the ID assigned to the specific database you want to save. The ID number for each database is listed in the left-top selection tool.
[Version 0.2.x] How can I discover the table names within a database?
To find the table names within a database follow these steps:
SELECT * FROM hello LIMIT 3
[Version 0.2.x] How can I sort the printed table (there is no sorting command available)?
Use SQL's ORDER
command. For instance, you can use SELECT * FROM hello ORDER BY x DESC
to sort the table based on the "x" column in descending order.
[Version 0.2.x] Can I create multiple plots in a single chart to compare multiple results?
Starting from version 0.1.1, you can draw multiple plots in a chart for easy comparison. To achieve this, ensure that all plot commands in a single computational box (active textbox) are written on separate lines without ending the lines with semicolons. This way, the extension consolidates all plots into a chart with different colors. However, note that any "math.js' statements followed by a semicolon will be hidden from the output to keep the chart clean and focused on the plotted data.
[Version 0.2.x] Is there a way to export a table into a CSV format file?
Whenever you have a table displayed in the view, you will notice an "Export" button located on the top left side of the table. By clicking this button, the table's data will be exported into a file named export.csv
. The file will be saved in the default download directory of your browser.
[Version 0.2.x] Is it possible to import a CSV tabular file into my SQLite database?
When you drop a file with the *.csv format into the view, the extension automatically converts the tabular data into an SQLite-friendly command. You can review the generated command, then press "Enter" to execute it and import the data into your SQLite database. Please be aware that only comma-separated CSV database files are supported by this extension.
[Version 0.2.x] How can I update a value in a printed table and make sure the change is also applied to the SQLite database?
To update a value in the printed table and have the change reflected in the SQLite database, follow these steps:
[Version 0.2.x] What customizations does the plot function offer?
The plot function provides several customizations that can be added as a query string to the last parameter of the function:
plot(xArray, yArray, 'key1=value1&key2=value, ...')
You can place each plot command on a single line to create multiple plots. This method allows you to group the plots seamlessly.
plot(sin(1:10), 'type=line')
)plot(sin(1:10), "type=scatter&showLine=false")
)plot([60, -20, 100], "type=bar")
)plot([60, 40, 100], "type=pie")
)plot([60, 40, 100], "type=doughnut")
)plot(sin(1:10), "label=my #$ plot")
)plot(sin(1:10), 'borderWidth=5')
)plot(sin(1:10), 'backgroundColor=red')
)plot(sin(1:10), 'borderColor=red')
)plot([60, 20, 100], "type=bar&hoverBackgroundColor=red")
)plot(sin(1:10), "steppedLine=after")
)[Version 0.2.x] Is it possible to execute SQLite commands from the "math.js" environment?
Yes, starting from version 0.2.4, you can execute arbitrary SQLite commands from the mathjs environment using the sql
method. This method requires two arguments. The first argument is the SQL command you want to execute, and the second argument is an object containing all the variables to be bound with the SQLite statement.
To run a simple SQLite command, you only need to provide the first argument, for example:
sql('SELECT * FROM table_name LIMIT 3')
Add the second argument to use "math.js" variables in the SQLite statement. For instance, let's assume there is a "math.js" variable called x
, and we want to search our table using the column name x
. To send variables to the SQLite side, always prepend them with the ":" symbol. For this case, the "math.js" command would be:
sql('SELECT * FROM table_name WHERE col=:c', {':c': x});
You can execute multiple SQLite commands by replacing the second argument with an array. For example, to add ten new records to our table, you can use the following method:
sql('INSERT INTO table_name(col) VALUES(:v)', map(1:10, f(x) = {':v': x}))
In this example, the map
function is used to convert an array of 1 to 10 into the array of objects required as the second argument for the SQLite statement.
[Version 0.2.x] Is it possible to import data from a JSON file into the SQLite database?
Yes, starting from version 0.2.4, if you drop a JSON file into the window, the "math.js" last
variable will be populated with the object representing the content of the JSON file. You can then use the sql
command to send this JSON information to the SQLite database.
[Version 0.2.x] Is it possible to update my SQLite database using a JSON object?
If you drop a valid JSON file into the computational window, the JSON will be parsed and get assigned to the "last" variable in the "math.js" environment. To update the database, you can execute one or more SQL statements using a new command called "sql(statement, [object or array of inputs])" in the "math.js" environment.
This "sql" command takes two input arguments. The first argument is the actual SQL statement, and the second, which is optional, is used to bind the statement with the "math.js" variables. For example, if you have a variable called "id" in the "math.js" environment and you want to see the queries that match this variable, you can run
sql('SELECT * from table_name where id=:id', {':id': id})
This command binds the "math.js" "id" with the SQLite statement, executes it, and prints the output in the computational box.
To run the statement on multiple ids, you can send an array of objects as the second argument. If the array is large and you would like to see the progress, you can open your browser console. To enhance performance, version 0.2.4 introduces a sandboxed JavaScript editor, which can be accessed from the managed menu item. Inside the JavaScript editor, you can access all "math.js" variables through the "mathjs" global variable. Additionally, you can use the "send(name, value)" command to send the output of JavaScript code back to the "math.js" environment. As we are in JavaScript, you can use "console.log" to print to the browser console window.
When dealing with large arrays, it is recommended to use the JavaScript editor to construct your array and then send the result to the "math.js" environment to execute SQL commands from this array, optimizing the process.
Please keep reviews clean, avoid improper language, and do not post any personal information. Also, please consider sharing your valuable input on the official store.
Using SQL/SQLite and managing multiple databases is undoubtedly a challenging task. It requires certain expertise and skills to view and manipulate data from multiple resources. SQLite Manager browser extension aims to make the use of SQLite easy for everyone. Whether they live up to this claim or not, you will get to know by reading this in-depth review of this extension.
SQLite Manager is definitely a must-have extension for every individual who deals with these databases on regular basis. It is extremely easy to use and provide you just the support you require when using multiple databases. With this extension, you will no longer have to go through the hassles of switching between your browser and SQL software to execute the SQL commands as you will be able to do this right from your browser. Furthermore, it also allows users to read multiple SQLite databases directly from their browser. Another prominent aspect that makes further surges up its importance is the option to create a new SQLite database. It allows easy creation of the database in the browser memory using a simple command. This database can be saved later in the computer hard disk if you need to have access to it later. Thus, all the hassles faced by a database manager while creating a new database are eliminated. This extension serves as a full-featured manager as it can support each and every standard command use to create and modify databases. It is equipped with two powerful libraries that further enhance its functionality and usability. These extensions include math.js and Chart.js. The former makes it easier to handle arrays and matrixes while the latter can prove to be useful when it comes to plotting 2D charts. Another powerful feature it boasts of is that it keeps a history of commands used. Thus, you can always go back and see the commands you have already used with this extension for reusing them. This extension uses JavaScript; hence, there is no requirement to use any native component. With this feature, your browser will not become sluggish and slow and security-wise there is no access to your personal data. In case you have forgotten a table name of a database, there is nothing to worry about as you can easily find it using the built-in tools. All you have to do is to open the manager window of this extension and drop the database there. Then, you will have to open the command menu, there you will spot the command for inspecting the database. Another outstanding feature is that it is free and, as stated above, easy to use. You will just have to install it and you can perform an array of function related to the database using this extension. It supports multiple manager windows in which multiple database files can be loaded simultaneously. Thus, you can work on as many databases as you like all at the same time. Talking about the flipsides, I didn’t find in this extension. Thus, I would suggest this extension to be used by every database manager.
Permission | Description |
---|---|
storage | to save internal preferences |