firebird

Database connection with Firebird Adapter in Zend Framework

浪子不回头ぞ 提交于 2019-12-10 14:31:47
问题 I just started to learn about ZF and Firebird because of a project I am assigned to. I have been trying to make the connection between both for several days now, but I haven't succeed yet. I tried ZF with PDO_Mysql and it works just fine as it does Firebird connection with PHP (out of ZF), but when I try to make the connection with the Firebird adapter in ZF it keeps displaying all kinds of errors. So, just to check. To make the connection in ZF with Firebird it should be done with the the

Firebird 2.5.2 change blob subtype

筅森魡賤 提交于 2019-12-10 13:58:59
问题 Is there a posibility to change the SUBTYPE of a BLOB field ? I have a BLOB with SUBTYPE BINARY an need to change it to SUBTYPE TEXT, because i get some strange Characters into the BLOB and in a BLOB with SUBTYPE TEXT i don't have this Problem 回答1: Directly altering the subtype of a blob column is not possible (attempts to do this will give the error "Cannot change datatype for column BLOBCOLUMN. Changing datatype is not supported for BLOB or ARRAY columns." ) You will need to Add a new

Entity Framework Generates different queries on different workstations

帅比萌擦擦* 提交于 2019-12-10 13:47:28
问题 We have problem on single Developer Machine and a few clients. Single Linq Query Generates two different SQL queries. The problem is in fact that second query has “OUTER APPLY” statement which firebird do not supports. We think that it isn’t Code issue, but environmental issue, but i will paste code. linq : AIds = (from x in context.RISK_T_ASSESS_HIST where (x.ID_RISKOBJECT.HasValue && x.F_CREATEDON >= Freq.StartDate && x.F_CREATEDON <= Freq.EndDate) group x by x.ID_RISKOBJECT into gr let

Firebird .NET provider and embedded server 3

梦想与她 提交于 2019-12-10 13:21:26
问题 I'm trying to use .NET Firebird Provider to connect to the embedded FB 3.0.1 server. As far as I know, (also written here (page 6)), there is no more fbclient.dll\fbembed.dll but a single client fbclient.dll used for remote and embedded access. But when I call the FBConnection.Open() I get a System.DllNotFoundException: Unable to load DLL 'fbembed': Impossible to find the specified module (Exception from HRESULT: 0x8007007E). Any ideas? 回答1: Looking in the Provider code the default Client

Update records in one table using another table's records as WHERE parameters

两盒软妹~` 提交于 2019-12-10 11:22:23
问题 I have 2 tables: Table1 and Table2. Both tables have a column named Column2. I want to set all values of Table1.Column1 as NULL for all records that do not exist in Table2. I.e. all records where Table1.Column2 <> Table2.Column2. This is the query I am trying to execute: UPDATE a SET a.Column1 = null FROM Table1 a INNER JOIN Table2 b ON a.Column2 <> b.Column2 I get a "Token Unknown" Dynamic SQL error on "FROM" when I try to execute this query. Any idea what I am doing wrong? I am fairly new

Is it possible to write large strings to Firebird blob?

柔情痞子 提交于 2019-12-10 10:34:49
问题 The documentation for Firebird implies that you can write large (> 60K) strings to a blob value in a table. So if you have this: CREATE TABLE MyBlobTable ( theId int PRIMARY KEY NOT NULL, theBlob BLOB SUB_TYPE 1 ) Then this should work: insert into MyBlobTable (theId, theBlob) values (1, '[60K characters in a string]') (example inspired by http://web.firebirdsql.org/dotnetfirebird/blob-sub_type-1-reading-example-csharp.html) But I've found that neither C# drivers nor FlameRobin can write this

Does Firebird BLR contain the related field sizes?

不问归期 提交于 2019-12-10 10:08:53
问题 Firebird and InterBase keep a compiled form of stored procedures and triggers in BLR (tokenized) format. But I do not really know the structure of BLR. Is field size the part of the BLR? Would I get some problems when a stored procedure contains two fields (source and destination), and later I'll change the size of these two fields? For example they were varchar(50) long, but now I change them to varchar(100) with system table updates. What will happen? Would it only copy 50 characters, or

Is there any way to create a local table variable inside a Firebird stored proc?

别说谁变了你拦得住时间么 提交于 2019-12-10 04:33:08
问题 In MS SQL Server, you can declare local variables of any primitive type, or of a table type. This table is a normal table that you can run SELECT , INSERT , UPDATE and DELETE on, just like any other table, except that it's a local variable, not a part of the database itself. I'm trying to do the same thing in Firebird, but it doesn't seem to like the syntax. declare variable value int; --works fine declare variable values table (value int); --Error: "Token unknown (table)" Is there any way to

Get list of column names from a Firebird database table

爱⌒轻易说出口 提交于 2019-12-09 04:44:54
问题 How do you get a list of the column names in an specific table? ie. Firebird table: | name | id | phone_number | get list like this: columnList = ['name', 'id', 'phone_number'] 回答1: if you want to get a list of column names in an specific table, this is the sql query you need: select rdb$field_name from rdb$relation_fields where rdb$relation_name='YOUR-TABLE_NAME'; I tried this in firebird 2.5 and it works. the single quotes around YOUR-TABLE-NAME are necessary btw 回答2: Get list of columns

Is it possible to rename a table in Firebird?

房东的猫 提交于 2019-12-08 19:42:03
问题 Is it possible to rename a table in Firebird or I should create a new table and then move the data using insert? 回答1: Apparently not. You must either create a new table, copying over old values or create a view with the intended name which is identical to the original table. See http://www.firebirdfaq.org/faq363/ for further details. 回答2: It is possible to change the column name by: ALTER TABLE "tableName" ALTER "columnName" TO "NewColumnName"; 来源: https://stackoverflow.com/questions/12291919