Sponsored Content
Full Discussion: SQL Lite query
Special Forums UNIX and Linux Applications SQL Lite query Post 302194487 by cbkihong on Tuesday 13th of May 2008 03:05:07 AM
Old 05-13-2008
I believe this FAQ from sqlite answers your question, if I understand correctly that you are trying to use the SQLite database engine.

SQLite Frequently Asked Questions
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

& in SQL query

I have a script that looks for all jobs that contain a particular calendar. Some of the calendars have '&' in them and sql freaks out when it encounters that.. is there a way around this? I have tried: select job_name from job where run_calendar='1&15dom' select job_name from job... (3 Replies)
Discussion started by: Lindarella
3 Replies

2. Shell Programming and Scripting

rsh and sql query

Hi ... I am doing a switch user and then rsh and then running a sql query . I am successfull in rsh and logging into the database , but my query doesnt run .. Here's the command : su - linus -c "rsh -l linus psmf ORACLE_SID=SMP;export ORACLE_SID;sqlplus... (1 Reply)
Discussion started by: sars
1 Replies

3. Shell Programming and Scripting

pro*c program for sql query

Hi all, I have sql query as follows. Please write a pro*c program for the following query. select sp1.cost_change ||','|| sp1.cost_change_desc ||','|| sp1.reason ||','|| to_char(sp1.active_date,'DD-MON-YYYY HH24:MI:SS') ||','|| sp1.status ||','|| sp1.cost_change_origin... (0 Replies)
Discussion started by: user71408
0 Replies

4. Shell Programming and Scripting

sql query problem

Hi, I am passing an argument for the script and that argument values should exist in database. bill_period_input="'""$1""'" bill_period=`sqlplus uname/pwd@dbname <<eof! set verify off set heading off set feedback off select bill_period from bill_period_ref where... (4 Replies)
Discussion started by: ss_ss
4 Replies

5. Shell Programming and Scripting

How to use sql data file in unix csv file as input to an sql query from shell

Hi , I used the below script to get the sql data into csv file using unix scripting. I m getting the output into an output file but the output file is not displayed in a separe columns . #!/bin/ksh export FILE_PATH=/maav/home/xyz/abc/ rm $FILE_PATH/sample.csv sqlplus -s... (2 Replies)
Discussion started by: Nareshp
2 Replies

6. Shell Programming and Scripting

create sql query

Hi Everyone, Can anyone pls help me out......with my requirement, i am struggling since 3 days. Please find the requirement below my file contains below data R1|Array/Network Resistor - VIP|V_RES_CLASS|V_MOUNT_FEATURE|SURFACE MOUNT|AND|8533.10.00.20|8533.10.00.20| R1|Array/Network Resistor... (9 Replies)
Discussion started by: jam_prasanna
9 Replies

7. Shell Programming and Scripting

problem in SQL query

I used the following code code select * from tablename where columnname Instead of printing the expected output it prints all the files in the present directory since there is a "*" in the code. Is there any way to overcome the problem? Thanks Ananth (2 Replies)
Discussion started by: Ananthdoss
2 Replies

8. Shell Programming and Scripting

Run SQL thru shell script: how to get a new line when run sql query?

Hi, this's Pom. I'm quite a new one for shell script but I have to do sql on shell script to query some information from database. I found a concern to get a new line...When I run my script, it retrieves all data as wondering but it's shown in one line :( What should I do? I'm not sure that... (2 Replies)
Discussion started by: Kapom
2 Replies

9. Programming

Getting error in sql query

Hi All , I have tried many times am getting syntax error on 'UNION' can anybody tell me ... INSERT INTO table1 ( Type , num_items , num_letters , total_value ) (select type='1', num_items, num_letters=count(*), total_value=sum(letter_value) from table2 where num_items = 1 (1 Reply)
Discussion started by: Venkatesh1
1 Replies

10. Programming

Help writing SQL query

Hello All, I hope I'm posting this in the right section. I have zero sql query writing skill, in fact, I've never done it before, but for some reason, a request came across my desk to get information from one of our databases. I have about 200 ticket numbers that have no information attached,... (8 Replies)
Discussion started by: bbbngowc
8 Replies
App::Info::RDBMS::SQLite(3pm)				User Contributed Perl Documentation			     App::Info::RDBMS::SQLite(3pm)

NAME
App::Info::RDBMS::SQLite - Information about SQLite SYNOPSIS
use App::Info::RDBMS::SQLite; my $sqlite = App::Info::RDBMS::SQLite->new; if ($sqlite->installed) { print "App name: ", $sqlite->name, " "; print "Version: ", $sqlite->version, " "; print "Bin dir: ", $sqlite->bin_dir, " "; } else { print "SQLite is not installed. :-( "; } DESCRIPTION
App::Info::RDBMS::SQLite supplies information about the SQLite application installed on the local system. It implements all of the methods defined by App::Info::RDBMS. Methods that trigger events will trigger them only the first time they're called (See App::Info for documentation on handling events). To start over (after, say, someone has installed SQLite) construct a new App::Info::RDBMS::SQLite object to aggregate new meta data. Some of the methods trigger the same events. This is due to cross-calling of shared subroutines. However, any one event should be triggered no more than once. For example, although the info event "Executing `pg_config --version`" is documented for the methods "name()", "version()", "major_version()", "minor_version()", and "patch_version()", rest assured that it will only be triggered once, by whichever of those four methods is called first. INTERFACE
Constructor new my $sqlite = App::Info::RDBMS::SQLite->new(@params); Returns an App::Info::RDBMS::SQLite object. See App::Info for a complete description of argument parameters. When it called, "new()" searches the directories returned by search_bin_dirs for an executable with a name returned by "search_exe_names". If found, it will be called by the object methods below to gather the data necessary for each. If it cannot be found, then "new()" will attempt to load DBD::SQLite or DBD::SQLite2. These DBI drivers have SQLite embedded in them but do not install the application. If these fail, then SQLite is assumed not to be installed, and each of the object methods will return "undef". Events: info Looking for SQLite. confirm Path to SQLite executable? unknown Path to SQLite executable? Class Method key_name my $key_name = App::Info::RDBMS::SQLite->key_name; Returns the unique key name that describes this class. The value returned is the string "SQLite". Object Methods installed print "SQLite is ", ($sqlite->installed ? '' : 'not '), "installed. "; Returns true if SQLite is installed, and false if it is not. App::Info::RDBMS::SQLite determines whether SQLite is installed based on the presence or absence of the sqlite3 or sqlite application on the file system as found when "new()" constructed the object. If SQLite does not appear to be installed, then all of the other object methods will return empty values. name my $name = $sqlite->name; Returns the name of the application. App::Info::RDBMS::SQLite simply returns the value returned by "key_name" if SQLite is installed, and "undef" if it is not installed. version my $version = $sqlite->version; Returns the SQLite version number. App::Info::RDBMS::SQLite parses the version number from the system call "`sqlite -version`" or retrieves it from DBD::SQLite. Events: info Executing `sqlite -version` error Failed to find SQLite version with `sqlite -version` Failed to retrieve SQLite version from DBD::SQLite Unable to parse name from string Unable to parse version from string Failed to parse SQLite version parts from string unknown Enter a valid SQLite version number major version my $major_version = $sqlite->major_version; Returns the SQLite major version number. App::Info::RDBMS::SQLite parses the version number from the system call "`sqlite -version`" or retrieves it from DBD::SQLite. For example, if "version()" returns "3.0.8", then this method returns "3". Events: info Executing `sqlite -version` error Failed to find SQLite version with `sqlite -version` Failed to retrieve SQLite version from DBD::SQLite Unable to parse name from string Unable to parse version from string Failed to parse SQLite version parts from string unknown Enter a valid SQLite version number minor version my $minor_version = $sqlite->minor_version; Returns the SQLite minor version number. App::Info::RDBMS::SQLite parses the version number from the system call "`sqlite -version`" or retrieves it from DBD::SQLite. For example, if "version()" returns "3.0.8", then this method returns "0". Events: info Executing `sqlite -version` error Failed to find SQLite version with `sqlite -version` Failed to retrieve SQLite version from DBD::SQLite Unable to parse name from string Unable to parse version from string Failed to parse SQLite version parts from string unknown Enter a valid SQLite version number patch version my $patch_version = $sqlite->patch_version; Returns the SQLite patch version number. App::Info::RDBMS::SQLite parses the version number from the system call "`sqlite -version`" or retrieves it from DBD::SQLite. For example, if "version()" returns "3.0.8", then this method returns "8". Events: info Executing `sqlite -version` error Failed to find SQLite version with `sqlite -version` Failed to retrieve SQLite version from DBD::SQLite Unable to parse name from string Unable to parse version from string Failed to parse SQLite version parts from string unknown Enter a valid SQLite version number executable my $executable = $sqlite->executable; Returns the path to the SQLite executable, usually sqlite3 or sqlite, which will be defined by one of the names returned by"search_exe_names()". The executable is searched for in "new()", so there are no events for this method. bin_dir my $bin_dir = $sqlite->bin_dir; Returns the SQLite binary directory path. App::Info::RDBMS::SQLite simply retrieves it as the directory part of the path to the SQLite executable. lib_dir my $lib_dir = $expat->lib_dir; Returns the directory path in which an SQLite library was found. The directory path will be one of the values returned by "search_lib_dirs()", where a file with a name as returned by "search_lib_names()" was found. No search is performed if SQLite is not installed or if only DBD::SQLite is installed. Events: info Searching for shared object library directory error Cannot find shared object library directory unknown Enter a valid Expat shared object library directory so_lib_dir my $so_lib_dir = $expat->so_lib_dir; Returns the directory path in which an SQLite shared object library was found. The directory path will be one of the values returned by "search_lib_dirs()", where a file with a name as returned by "search_so_lib_names()" was found. No search is performed if SQLite is not installed or if only DBD::SQLite is installed. Events: info Searching for shared object library directory error Cannot find shared object library directory unknown Enter a valid Expat shared object library directory inc_dir my $inc_dir = $sqlite->inc_dir; Returns the directory path in which an SQLite include file was found. The directory path will be one of the values returned by "search_inc_dirs()", where a file with a name as returned by "search_inc_names()" was found. No search is performed if SQLite is not installed or if only DBD::SQLite is installed. Events: info Searching for include directory error Cannot find include directory unknown Enter a valid SQLite include directory home_url my $home_url = $pg->home_url; Returns the PostgreSQL home page URL. download_url my $download_url = $pg->download_url; Returns the PostgreSQL download URL. search_exe_names my @search_exe_names = $sqlite->search_exe_names; Returns a list of possible names for the SQLite executable. The names are sqlite3 and sqlite by default (sqlite3.exe and sqlite.exe on Win32). search_bin_dirs my @search_bin_dirs = $sqlite->search_bin_dirs; Returns a list of possible directories in which to search an executable. Used by the "new()" constructor to find an executable to execute and collect application info. The found directory will also be returned by the "bin_dir" method. search_lib_names my @seach_lib_names = $self->search_lib_nams Returns a list of possible names for library files. Used by "lib_dir()" to search for library files. By default, the list is: libsqlite3.a libsqlite3.la libsqlite3.so libsqlite3.so.0 libsqlite3.so.0.0.1 libsqlite3.dylib libsqlite3.0.dylib libsqlite3.0.0.1.dylib libsqlite.a libsqlite.la libsqlite.so libsqlite.so.0 libsqlite.so.0.0.1 libsqlite.dylib libsqlite.0.dylib libsqlite.0.0.1.dylib search_so_lib_names my @seach_so_lib_names = $self->search_so_lib_nams Returns a list of possible names for shared object library files. Used by "so_lib_dir()" to search for library files. By default, the list is: libsqlite3.so libsqlite3.so.0 libsqlite3.so.0.0.1 libsqlite3.dylib libsqlite3.0.dylib libsqlite3.0.0.1.dylib libsqlite.so libsqlite.so.0 libsqlite.so.0.0.1 libsqlite.dylib libsqlite.0.dylib libsqlite.0.0.1.dylib search_lib_dirs my @search_lib_dirs = $sqlite->search_lib_dirs; Returns a list of possible directories in which to search for libraries. By default, it returns all of the paths in the "libsdirs" and "loclibpth" attributes defined by the Perl Config module -- plus /sw/lib (in support of all you Fink users out there). search_inc_names my @search_inc_names = $sqlite->search_inc_names; Returns a list of include file names to search for. Used by "inc_dir()" to search for an include file. By default, the names are sqlite3.h and sqlite.h. search_inc_dirs my @search_inc_dirs = $sqlite->search_inc_dirs; Returns a list of possible directories in which to search for include files. Used by "inc_dir()" to search for an include file. By default, the directories are: /usr/local/include /usr/include /sw/include BUGS
Please send bug reports to <bug-app-info@rt.cpan.org> or file them at <http://rt.cpan.org/NoAuth/Bugs.html?Dist=App-Info>. AUTHOR
David Wheeler <david@justatheory.com> SEE ALSO
App::Info documents the event handling interface. App::Info::RDBMS is the App::Info::RDBMS parent class from which App::Info::RDBMS::SQLite inherits. DBD::SQLite is the DBI driver for connecting to SQLite databases. <http://www.sqlite.org/> is the SQLite home page. COPYRIGHT AND LICENSE
Copyright (c) 2004-2008, David Wheeler. Some Rights Reserved. This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.10.1 2011-03-15 App::Info::RDBMS::SQLite(3pm)
All times are GMT -4. The time now is 05:19 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy