I've almost used SQL server_SDE geodatabases for 3 years in GIS projects and I don't know how can I create a stored procedure in geodatabase.I use ESRI case tool to create a geodatabase in ArcCatalog(using xml file as described in ESRI documentations),so I never created a geodatabase with DDL scripts,But i would like to know (and do) creating a geodatabase using DDL commands in SQL Server(while using SDE and versioning) and adding stored procedure to this geodatabase.As I know,sde creates some metadata tables and breaks data of versioned tables into some other tables(like a_xx and f_xx,for example a89,f89) so that some records of table is saved in these helping tables,so that I don't know how can I find the name of these helping tables and basically do i have to work with them in stored procedure or not.

Is there any document or guide line to show how can create a geodatabase using DDL command in an environment like SQL server management studio?and how can create stored procedures in geodatabase and how can call it?

1 Answer 1


The SQL Server geodatabases are like any other SQL Server database. Writing and accessing stored procedures for data in the geodatabases will not be any different.

Here is a presentation from ESRI on how to use SQL in a geodatabase:


  • Thank you very much Seth,I found this file useful,but not enough details included as it's a presentation.do you think it's possible to work with a geoDB using an object model other than ArcObject,say ODBC or OLEDB,just like a a non_GeoDB database in ESRI's application?
    – Reza
    Commented Feb 21, 2011 at 4:44
  • @Reza - Entity Framework 4 offers some support to modeling geodatabases, even though it currently requires a hack to represent spatial types. You may want to give that a try. Commented Feb 21, 2011 at 4:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.