[Firebird-net-provider] [FB-Tracker] Created: (DNET-708) DbModelBuilder.Entity().MapToStoredProcedures() creates an empty procedure

2016-10-20 Thread Charles J Christie II (JIRA)
DbModelBuilder.Entity().MapToStoredProcedures() creates an empty 
procedure
---

 Key: DNET-708
 URL: http://tracker.firebirdsql.org/browse/DNET-708
 Project: .NET Data provider
  Issue Type: Bug
  Components: Entity Framework support
Affects Versions: 5.5.0.0
 Environment: Windows 7, Visual Studio 2015 Enterprise, Firebird 
3.0.0.32485, EntityFramework.Firebird 5.5.0, FirebirdSql.Data.FirebirdClient 
5.5.0
Reporter: Charles J Christie II
Assignee: Jiri Cincura
Priority: Minor


I attempted to map my entities as procedures in the model builder. I then went 
to test my database and, upon calling SaveChanges on my context, I got the 
following exception:
"Dynamic SQL Error
SQL error code = -84
procedure Address_Insert does not return any values
At line 1, column 15"

I opened the database using DBeaver and loaded the code used for the generated 
stored procedure:
CREATE OR ALTER PROCEDURE Address_Insert ("FirstName" VARCHAR(100), "LastName" 
VARCHAR(100), "AttnLine" VARCHAR(100), "Line1" VARCHAR(255), "Line2" 
VARCHAR(255), "City" VARCHAR(50), "State" VARCHAR(50), "Zip" VARCHAR(10), 
"Country" VARCHAR(53), "Job_Id" INTEGER, "Profile_Id" INTEGER)
AS
BEGIN

END

And in the migration:
CreateStoredProcedure(
"dbo.Address_Insert",
p => new
{
FirstName = p.String(maxLength: 100),
LastName = p.String(maxLength: 100),
AttnLine = p.String(maxLength: 100),
Line1 = p.String(maxLength: 255),
Line2 = p.String(maxLength: 255),
City = p.String(maxLength: 50),
State = p.String(maxLength: 50),
Zip = p.String(maxLength: 10),
Country = p.String(maxLength: 53),
Job_Id = p.Int(),
Profile_Id = p.Int(),
},
body: ""
);

All of the generated stored procedures have the same problem. They're all 
completely blank.
For now I won't use them. I'd suggest that if you don't want to implement this 
functionality any time soon, that you make it throw a NotImplementedException 
if you can, or have it prominently shown in your documentation that it doesn't 
do anything. Thank you.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://tracker.firebirdsql.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Firebird-net-provider mailing list
Firebird-net-provider@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider


[Firebird-net-provider] [FB-Tracker] Created: (DNET-707) Invalid SQL generated for migration if changing a column from null to not null

2016-10-20 Thread Charles J Christie II (JIRA)
Invalid SQL generated for migration if changing a column from null to not null
--

 Key: DNET-707
 URL: http://tracker.firebirdsql.org/browse/DNET-707
 Project: .NET Data provider
  Issue Type: Bug
  Components: Entity Framework support
Affects Versions: 5.5.0.0
 Environment: Windows 7, VS 2015 Enterprise, EF 6.1.3, 
EntityFramework.Firebird 5.5.0, FirebirdSql.Data.FirebirdClient 5.5.0, Firebird 
3.0.0.32485
Reporter: Charles J Christie II
Assignee: Jiri Cincura


I changed a column's type and null constraint during development of a new 
application. I found out later that Firebird doesn't support that through the 
ALTER TABLE ALTER COLUMN syntax, and that other options are available here: 
http://www.firebirdfaq.org/faq103/

Here's the line that was generated by migrations when I changed the data type 
on a property from Nullable to long:

ALTER TABLE "Booklets" ALTER COLUMN "File_Size" TYPE BIGINT NOT NULL
;

Apparently, according to that page, all admin tools change the value on the 
system table. Maybe we should do that here too.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://tracker.firebirdsql.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Firebird-net-provider mailing list
Firebird-net-provider@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider