Does the opposite of gda.global.textToAlphanum, in the same string
Creates an array of strings (terminated by a null) corresponding to possible completions. If no completion is available, then the returned array contains just one NULL entry, and if it was not possible to try to compute a completions list, then null is returned.
Creates an INSERT, an UPDATE and a DELETE statement from a SELECT statement using the database metadata available in cnc's meta store. Each statements are computed only if the corresponding place to store the created statement is not null.
Extract the DSN, username and password from string. in string, the various parts are strings which are expected to be encoded using an RFC 1738 compliant encoding. If they are specified, the returned username and password strings are correctly decoded.
Escapes string to make it understandable by a DBMS. The escape method is very common and replaces any occurrence of "'" with "''" and "\" with "\\"
Converts a named type to ts GType type (also see the gda.global.gTypeToString function).
Converts a GType to its string representation (use gda.global.gTypeFromString for the operation in the other direction).
Find the path to the application identified by app_name. For example if the application is "gda-sql", then calling this function will return "/your/prefix/bin/gda-sql-5.0" if Libgda is installed in the "/your/prefix" prefix (which would usually be "/usr"), and for the ABI version 5.0.
Does the same as strcmp(id1, id2), but handles the case where id1 and/or id2 are enclosed in double quotes. can also be used in hash tables as a #GEqualFunc.
computes a hash string from id, to be used in hash tables as a #GHashFunc
Initializes the GDA library, must be called prior to any Libgda usage.
Call this function whenever the setlocale() function has been called to change the current locale; this function is first called by gda.global.init_ so you don't need to call it if you have set the locale before calling gda.global.init_.
Disables GDA logs.
Enables GDA logs.
This function is similar to gda.global.parseIso8601Date (with first being G_DATE_YEAR, second being G_DATE_MONTH, third being G_DATE_DAY and sep being '-') but allows one to specify the expected date format.
This function is similar to gda.global.parseIso8601Timestamp (with first being G_DATE_YEAR, second being G_DATE_MONTH, third being G_DATE_DAY and sep being '-') but allows one to specify the expected date format.
Extracts date parts from value, and sets gdate's contents
Extracts time parts from value, and sets timegda's contents
Extracts date and time parts from value, and sets timestamp's contents
Modifies stmt to take into account any parameter which might be null: if stmt contains the equivalent of "xxx = <parameter definition>" and if that parameter is in params and its value is of type GDA_TYPE_NUL, then that part is replaced with "xxx IS NULL". It also handles the "xxx IS NOT NULL" transformation.
Decodes string using the RFC 1738 recommendations: the <constant><>"#%{}|\^~[]'`;/?:@=&</constant> and space characters are replaced by <constant>"%ab"</constant> where <constant>ab</constant> is the hexadecimal number corresponding to the character.
Encodes string using the RFC 1738 recommendations: the <constant><>"#%{}|\^~[]'`;/?:@=&</constant> and space characters are replaced by <constant>"%ab"</constant> where <constant>ab</constant> is the hexadecimal number corresponding to the character.
Creates a new #GdaStatement, selecting the same data as stmt, but which always returns an empty (no row) data model. This is use dy database providers' implementations.
Use this function for any SQL identifier to make sure that: <itemizedlist> <listitem> <para>it is correctly formatted to be used with cnc (if cnc is null, then some default SQL quoting rules will be applied, similar to PostgreSQL's way) if for_meta_store is false; </para> </listitem> <listitem> <para>it is correctly formatted to be used with the #GdaMetaStore's object associated to cnc is for_meta_store is true. </para> </listitem> </itemizedlist>
Splits id into an array of it sub parts. id's format has to be "<part>[.<part>...]" where each part is either a text surrounded by double quotes which can contain upper and lower cases or an SQL identifier in lower case.
Performs the reverse of gda.binary.Binary.toString_ (note that for any "\xyz" succession of 4 characters where "xyz" represents a valid octal value, the resulting read value will be modulo 256).
Performs the reverse of gda.blob.Blob.toString_.
The "encoding" consists in replacing non alphanumeric character with the string "__gdaXX" where XX is the hex. representation of the non alphanumeric char.
Do the reverse of gda.global.defaultEscapeString: transforms any "''" into "'", any "\\" into "\" and any "\'" into "'".
Check the column types of a GdaDataModel.
Dump the data in a #GdaDataModel into a xmlNodePtr (as used in libxml).
Finds the description of a field into Metadata from a #GdaDataModel.
Note: this method may set the "source" custom string property
Compares two values of the same type, with the exception that a value of any type can be compared to a GDA_TYPE_NULL value, specifically: <itemizedlist> <listitem><para>if value1 and value2 are both GDA_TYPE_NULL values then the returned value is 0</para></listitem> <listitem><para>if value1 is a GDA_TYPE_NULL value and value2 is of another type then the returned value is -1</para></listitem> <listitem><para>if value1 is of another type and value2 is a GDA_TYPE_NULL value then the returned value is 1</para></listitem> <listitem><para>in all other cases, value1 and value2 must be of the same type and their values are compared</para></listitem> </itemizedlist>
Tells if two values are equal or not, by comparing memory representations. Unlike gda.global.valueCompare, the returned value is boolean, and gives no idea about ordering.
Converts a GValue to its string representation which is a human readable value. Note that the returned string does not take into account the current locale of the user (on the contrary to the #GdaDataHandler objects). Using this function should be limited to debugging and values serialization purposes.
Global functions for gda5 library