Conversion of @@IDENTITY in SQL Server

Hi,
Just wanted to know if anyone has run into this.
The migration tool warns that @@IDENTITY has be treated as a
normal variable.
It looks like:
select DEFINED_SEQ.CURRVAL should be the equivalent,
not sure how foolproof it will be in a multiuser environment.
Thanks.
Ramki..
null

Ramki,
In a multi user envirnment you may want to select from the
'identity' coloum inserted into, in case the sequence has been
used in the meantime by other users...
Turloch
Oracle Migration Workbench Team
Ramki (guest) wrote:
: Hi,
: Just wanted to know if anyone has run into this.
: The migration tool warns that @@IDENTITY has be treated as a
: normal variable.
: It looks like:
: select DEFINED_SEQ.CURRVAL should be the equivalent,
: not sure how foolproof it will be in a multiuser environment.
: Thanks.
: Ramki..
null

Similar Messages

  • Is it possible to Deploy a SSIS package to catalog with a Sql Server Identity in SQL Server 2012 programmly ?

    Hi,
    how can I deploy a SSIS package with a SQL SERVER identity to the catalog in SQL Server 2012 programmly?
    I tried to use the [SSISDB].[catalog].[deploy_project], but the error said that it could only be used with a WINDOWS identity.
    This question has worried me for days.
    Is there any way to make the catalog.deploy_project available for a SQL SERVER identity ?
    Or just an new solution instead of using the catalog.deploy_project?
    best wishes from Qingyuan Lee.

    Sorry, my description may be confusable.
    I use EXECUTE AS , not EXECUTE WITH, to solve the problem.
    In fact,  I don't care about the authority.
    I want to execute the stored procedure using a SQL SERVER Authentication Account , since my codes run on a linux OS and it is hard to connect to SSIS using a Windows Authentication Account.
    so, using EXECUTE AS to change the execution context is accaptable.
    The requirement for a Windows Authentication Account makes sense.
    I consider that the SSIS executes outside the context of SQL Server and as part of an OS process, which means that a Windows account is necessary in order to deploy a package.
    Thanks very much for your help.

  • Query conversion from access to sql server

    I have sql in access I need to convert to sql server . I am stuck three days please help me
    TRANSFORM First(Eval1to4.answer) AS FirstOfanswer SELECT Eval1to4.evalOid, Membershiptypemap.mappedvalue as membership, First(Eval1to4.answer) AS [Total Of answer] FROM (Members RIGHT JOIN (Eval1to4 LEFT JOIN Orders ON Eval1to4.evalOid = Orders.oid) ON Members.CID
    = Orders.cid) LEFT JOIN MembershipTypeMap ON (Members.MembershipStatus = MembershipTypeMap.membershipstatus) AND (Members.Membership = MembershipTypeMap.membershiptype) WHERE Orders.program = 20141128 AND Eval1to4.evalProgID=20141128 GROUP BY Eval1to4.evalOid,
    Membershiptypemap.mappedvalue PIVOT Eval1to4.questionID

    There isn't an exact equivalent to pivot queries in t-sql.
    There is a pivot operator but it requires that you know and explicitly specify the pivoted columns when you're creating your code.
    Just a heads up... Some one here will most assuredly either provide you with or point you to code that will allow you to do a "dynamic pivot"... Yes, it will allow you to pivot the data the way you're used to doing it in Access (without having
    to specify the pivoted column names). The problem with dynamic pivots is the fact that they are useless. You can't put them in views, functions or stored procs and I'm not aware of any reporting software that can work with a variable number of input columns.
    So, unless you simply want to copy & paste from SSMS to Excel, they aren't good for anything other than patting yourself on the back.
    So... My 1st suggestion is to not pivot the data at all in SQL. Instead, pivot the data in whatever application you're using to display the data.
    Since no one ever wants to hear suggestion #1, use aggregated case expressions. Based on the code you provided, it should look kinda like this...
    SELECT
    Eval1to4.evalOid,
    Membershiptypemap.mappedvalue as membership,
    SUM(CASE WHEN Eval1to4.answer = 1 THEN 1 END) AS Answer1,
    SUM(CASE WHEN Eval1to4.answer = 2 THEN 1 END) AS Answer2,
    SUM(CASE WHEN Eval1to4.answer = 3 THEN 1 END) AS Answer3,
    SUM(CASE WHEN Eval1to4.answer = 4 THEN 1 END) AS Answer4,
    SUM(CASE WHEN Eval1to4.answer = 5 THEN 1 END) AS Answer5
    FROM
    Eval1to4 e
    JOIN Orders o
    ON e.evalOid = o.oid
    JOIN Members m
    ON m.CID = o.cid
    LEFT JOIN MembershipTypeMap mtm
    ON m.MembershipStatus = mtm.membershipstatus
    AND m.Membership = mtm.membershiptype
    WHERE
    o.program = 20141128
    AND e.evalProgID = 20141128
    GROUP BY
    e.evalOid,
    mtm.mappedvalue
    #3... There is still the "PIVOT" operator. I personally don't use it because the aggregated case expressions are more flexible... But some people love them, so do a little Googleing and decide for yourself.
    #4... Dynamic Pivot... If you're dying to try it, the interwabs are full of examples... or wait a bit and someone will post some for you.
    HTH,
    Jason
    Jason Long

  • SQL SERVER IDENTITY COLUMN TO ORACLE

    In SS you have an identity column that automatically updates to
    the next available number when you insert a new record. How can
    I get the same functionality in O8i. I understand about adding
    a sequence but how do i link that to a column that is my primary
    key. ie when I insert a new record I want the value for the
    primary to be automatically inserted.
    Thanks in advance for helping this dofbrain
    null

    Oracle Migration Workbench Team wrote:
    : Jonathan,
    : A similar question is:
    : >What's your general strategy in database conversion when
    dealing
    : with SQL server datatypes of 'identity'. Do you suggest a
    : sequence, with a before insert 'for each row' trigger? which
    will
    : insert the sequence.nextval into
    : the column?
    : Basically that is what we do.
    : The following is an example of what the Oracle Migration
    : Workbench does:
    : sqlserver code:
    : create procedure dbo.p_report_acc_bal_turn_list2
    : as
    : declare @myint integer
    : create table temp_x_y (sales_id int identity(20,10))
    : select @myint=1
    : becomes:
    : CREATE OR REPLACE PROCEDURE p_report_acc_bal_turn_list2
    : AS
    : StoO_selcnt INTEGER;
    : StoO_error INTEGER;
    : StoO_rowcnt INTEGER;
    : StoO_crowcnt INTEGER := 0;
    : StoO_fetchstatus INTEGER := 0;
    : StoO_errmsg VARCHAR2(255);
    : StoO_sqlstatus INTEGER;
    : myint INTEGER;
    : BEGIN
    : /*[SPCONV-ERR(7)]:CREATE TABLE temp_x_y statement passed
    : to ddl file*/
    : DELETE FROM temp_x_y;
    : p_report_acc_bal_turn_list2.myint := 1;
    : END p_report_acc_bal_turn_list2;
    : result ddl:
    : [These statements need to be run before procedure is built]
    : DROP TABLE temp_x_y
    : create table temp_x_y (
    : sales_id INTEGER
    : CREATE SEQUENCE temp_x_y_sales_id MINVALUE 0 START WITH 20
    : INCREMENT BY 10
    : CREATE TRIGGER TR_temp_x_y_sales_id BEFORE INSERT ON temp_x_y
    FOR
    : EACH ROW
    : BEGIN SELECT temp_x_y_sales_id.nextval INTO :new.sales_id FROM
    : dual; END
    : Turloch
    : Oracle Migration Workbench Team
    : Jonathan Howard (guest) wrote:
    : : In SS you have an identity column that automatically updates
    to
    : : the next available number when you insert a new record. How
    : can
    : : I get the same functionality in O8i. I understand about
    : adding
    : : a sequence but how do i link that to a column that is my
    : primary
    : : key. ie when I insert a new record I want the value for the
    : : primary to be automatically inserted.
    : : Thanks in advance for helping this dofbrain
    : Oracle Technology Network
    : http://technet.oracle.com
    null

  • March's TechNet Wiki SQL Server Guru Winners announced!!

    The results for March'sTechNet
    Guru competition have been posted!
    http://blogs.technet.com/b/wikininjas/archive/2014/04/17/the-microsoft-technet-guru-awards-march-2014.aspx <- results page!
    Congratulations to all our new Gurus for March!
    We will be interviewing some of the winners and highlighting their achievements, as the month unfolds.
    Below is a summary of the medal winners, the last column being a few of the comments from the judges.
    Unfortunately, runners up and their judge feedback comments had to be trimmed from THIS post, to fit into the forum's 60,000 character limit, however the full version is shown in the link above.
    Some articles only just missed out, so we may be returning to discuss those too, in future blogs.
     BizTalk Technical Guru - March 2014  
    Tomasso Groenendijk
    Using BAM in the ESB Toolkit
    Ed Price: "Incredibly valuable and very well written! Great article!"
    Mandi Ohlinger: "A custom BAM dashboard - LOVE it! Another great ESB addition to the Wiki."
    TGN: "Nice one, I really liked this one, explains how to use the ESB together with BAM, great work and well explained!"
    Steef-Jan Wiggers
    Windows Azure BizTalk Services: Pulling Messages from a Service Bus Queue
    Ed Price: "This is amazingly well written with beautiful images and formatting. Great job!"
    TGN: "Azure, Azure, Azure! Nice one Steef-Jan, people are waiting on articles like this. Good job, and thanks for the contribution!"
    Mandi Ohlinger: "A very informative How To. Screen shots are very helpful."
    boatseller
    Detecting a Missing Message
    Mandi Ohlinger: "GREAT addition to the Wiki and to any user who suspects missing messages. The BizTalk support team can use this orchestration. "
    Ed Price: "I love the visuals on the orchestration implementation! Important topic!"
    TGN: "Nice article, great to see a solution to detect missing files."
     Forefront Identity Manager Technical Guru - March 2014  
    Eihab Isaac
    FIM 2010 R2 BHOLD: Non-BHOLD Approval Process
    Ed Price: "Very thorough explanations! Great formatting and colors on the tables and code snippets! And the images are also helpful!"
    PG: "Nice article, we need more of these."
    Micah Rowland
    FIM:How To Use PowerShell to View a Metaverse Object's Connector's Attribututes
    Side By Side
    PG: "Nice article, nice format. well written"
    Ed Price: "Good code snippet and use of code comments. Could use more explanations and maybe breaking the code into sections with more information about each section. Good job!"
    Giriraj Singh
    FIM:Delete Bulk Expected Rule Entries Using FIM OTB features
    Ed Price: "Good procedural steps! It could benefit from more explanations, a grammar pass, and some images. Good article!"
    PG: "Short but nice article."
     SharePoint 2010 / 2013 Technical Guru - March 2014  
    Matthew Yarlett
    SharePoint: Use PowerShell to find Fields using a Managed Metadata TermSet
    Jinchun Chen: "Good article."
    Ed Price: "Although this is Matt's shorter article this month, this is an incredibly important topic, and the code is perfect! As Dan says in the comments: "Matthew Yarlett has done it again!! IMHO when it comes to SharePoint powershell
    you are second to none." This is a great article!" 
    Rahul A Shinde
    SharePoint 2013: Deploy and apply theme to SharePoint sites with PowerShell
    Ed Price: "Fantastic explanations and use of images!" 
    Matthew Yarlett
    SharePoint: Testing Email Alerts in UAT and DEV Environments
    Jinchun Chen: "Nice! It can be used for troubleshooting SharePoint Incoming/Outgoing related issues too."
    Ed Price: "Wow! This article is astonishingly thorough!"
     Small Basic Technical Guru - March 2014  
    Nonki Takahashi
    Small Basic: Centering Text in Graphics Window
    RZ: "Clearly written explanation with nice graphics to go with it."
    Ed Price: "I love having the three options like this! And the images really bring it to life! The links to the shared programs (with their source code) really help if you want to dig deeper and learn more!"
    Nonki Takahashi
    Small Basic Known Issue: 23589
    - Controls.GetTextBoxText() Returns CR+LF as Newline from Multi-Line Text Box in Local but CR in Remote
    RZ: "Bugs are always hard to track down, especially the unknown unknowns :( Good job on hunting it down!"
    Ed Price: "This acts as a valuable KB article! Great addition to the troubleshooting library!"
    Nonki Takahashi
    Small Basic: Expression
    RZ: "Good introduction to expressions"
    Ed Price: "Short and sweet intro to Expressions. Thanks, Nonki!"
     SQL BI and Power BI Technical Guru - March 2014  
    Michael Amadi
    A Practical Example of How to Apply Power Query Data
    Transformations on Structured and Unstructured Datasets
    NN: "This is a terrific tutorial on Power Pivot with very helpful images. Great article"
    Ed Price: "This is a fantastic combination of Power Query and Power Pivot... a valuable contribution!"
     SQL Server General and Database Engine Technical Guru - March 2014  
    chandra sekhar pathivada
    managing database backups across all the instances without maintenance plan
    Samuel Lester: "Chandra, outstanding contribution and information! Your SSIS package handles many of the shortcomings of Maintenance Plans. MPs were originally created to assist DBAs with the more common administrative
    tasks, but as the scale continues to grow across enterprise environments, we're all forced to write our own enhanced versions such as this. Thanks for the addition and please do add to the Gallery if you haven't yet."
    Jinchun Chen: "Nice. It is suggested to add error outputs in the package to handler unexpected errors."
    NN: "Good article. The SSIS solution can use a bit more explanation. Also See Also section is missing"
    DRC: "This is good article, The only this which can be corrected is : ==> This can be achieved using “maintenance Cleanup Task • Maintenance Plan has a control flow item “maintenance Cleanup Task” to delete the old backup files based
    on age of the backup, but it creates the problem when it deletes the full database backups based on n no.of days leaving all the dependent intermediate differential and transaction logs which are useless. "
    Shanky
    Understanding Logging in Tempdb.Is Tempdb re-created or rebuilt after SQL
    Server restart
    NN: "Very good article with an interesting analysis"
    DRC: "This article is good and provides lots of detailed information along with sample query and screenshot. The screenshot of few need few more details (files of model are missing) This article can be broken down into 2 1) understanding
    tempdb recreation 2) Logging in Tempdb 1) understanding tempdb recreation:- This is not concluded properly. The article doesnt talk about the physical files which are recreated even if we delete the tempdb files "
    Samuel Lester: "Shanky, very nice article on the internals of TempDB! It was tough judging this month as both articles were very informative contributions!" 
     System Center Technical Guru - March 2014  
    Mr X
    How to manage VM pinning within a Hyper-V cluster by
    combining the use of System Center VMM and Orchestrator
    Ed Price: "Mr. X, this is another incredibly thorough article! Fantastic job!"
    Idan Vexler
    Create Custom XML For OSD In SCCM  
    Ed Price: "Love the list of requirements! Very thorough in dividing each step!"
    Omar Lopez (loplim)
    SCOM 2012 - Create Alert / Monitor Based on Windows event ( Administrator login
    alert )
    Ed Price: "Good use of images. Could use a TOC with sections and more descriptions. Good job!"
     Transact-SQL Technical Guru - March 2014  
    Jayakumaur (JK)
    Understanding IDENTITY in SQL Server
    Ed Price: "Wow, what a competitive month! This article is amazing, with thorough explanations in each section!"
    Richard Mueller: "A good tutorial on an important feature of T-SQL."
    Durval Ramos
    Paging a Query with SQL Server
    Ed Price: "Durval's article is fantastically thorough and easy to follow!"
    Richard Mueller: "Very useful concept when populating controls from a query, which should improve performance. I like the images. Well done."
    Naomi N
    T-SQL: Split String with a Twist
    Richard Mueller: "Very intersting problem with an original solution."
    Ed Price: "A very powerful and well-articulated solution from Naomi!"
     Visual Basic Technical Guru - March 2014  
    The Thinker 
    Exporting and Importing Wireless Settings Using Netsh in VB.NET
    SB: "Code could be formatted better, task is something I can see as potentially useful although I would prefer a bit more narrative description and comments in the code explaining why it was done a certain
    way, although the code is simple enough to work through." 
    MR: "Great tool code!" 
    Ed Price: "This is a good contribution! One way to improve an article like this is to explain the parts of the code more in depth, as a way to introduce each snippet (and maybe dividing a block up more). Then you could link to the Gallery
    iteam if the reader wants to access the entire snippet at once. The images are also very helpful! Great job!" 
    Richard Mueller: "Perhaps this code should be in the gallery. There should be more explanation in a Wiki."
     Visual C# Technical Guru - March 2014  
    João Sousa
    ASP.NET WebAPI 2 - Stream Windows Azure blobs
    NN: "Very nice tutorial and also can be downloaded from the Gallery"
    Ed Price: "I love to see this ASP.NET content! Each step is very clear! Great code formatting!"
    Raghunathan S
    C# Code Compilation at Runtime from C# Windows Forms Application
    Ed Price: "Good descriptions and code formatting. It could benefit from a TOC. Great article!"
    NN: "This looks like an interesting article, but too short and the code is hard to read in its present format"
    Raghunathan S
    Creating a Simple logging class with System.Diagnostics namespace in C#
    NN: "Good article, but too short"
    Ed Price: "This is a pretty good article. It could benefit from a TOC and more descriptions around what the code is doing and why. Good job!"
     Wiki and Portals Technical Guru - March 2014  
    Matthew Yarlett
    Wiki: Basic Image Formatting using Pixlr
    BL: "This deserves credit as much for the idea as for the actual article - many authors contribute from computers that may not have authoring tools installed and this simple online solution has the potential to iprove
    quality a lot."
    Richard Mueller: "Excellent explanation of a useful tool for Wiki authors. A "See Also" section would be useful."
    PG: "Nice artilce, well done, nice layout. Great!"
    NN: "Good article"
    Durval Ramos
    VBA & VBS Portal
    NN: "Very good new portal about VBA. Introduction may be improved a bit"
    Richard Mueller: "A great collection of Wiki articles. Excellent use of recommended features in a Wiki article."
    PG: "Nice article good start!"
    BL: "Another great initial compilation of relevant resources. Would be very interested in seeing how this develop over time."
    Mr X
    Wiki: System Center Orchestrator Portal
    NN: "Good new portal. Missing See Also section with links to other portals"
    Richard Mueller: "A good collection of articles. This Portal adds a lot to the TechNet Wiki."
    PG: "Nice and neat article? Suggestion to add more references to related articles and platforms on Wiki."
    BL: "great initial compilation of SC Orchestrator resources. Hoping this will grow over time as the product has a few other active Wiki contributors."
     Windows Phone and Windows Store Apps Technical Guru - March 2014  
    Isham Mohamed
    Pin Windows Phone 8 app to start screen on first launch.
    Peter Laker: "A very useful and informative article! Also, Nice use of fonts and images."
    Ed Price: "Good explanation, but it could benefit from a TOC and tweaked formatting. Good job!"
    Ibraheem Osama Mohamed
    Coming from an asp.net background, let’s build our first Windows Store Application
    Ed Price: "Great job on the formatting, explanations, and code snippets!"
    Peter Laker: "Excellent primer for those moving from asp.net and all beginners."
    mcosmin
    The Performance Analyzer Paradox
    Ed Price: "This is a good philosophical article, but it would be richer with examples and visuals. "
    Peter Laker: "Nice story, good reading, very worthy entry and gratefully received!"
     Windows Presentation Foundation (WPF) Technical Guru - March 2014  
    Magnus (MM8)
    WPF/MVVM: Handling Changes To Dependency Properties In The View
    Ed Price: "Nice, thorough topic with good explanations! Could benefit from code formatting. Great article!"
    Peter Laker: "A nice primer on a fundamental aspect of xaml. Great layout, images, descriptions, etc."
    dev hedgehog
    Trick To Use StaticResource With Path
    Peter Laker: "A very useful and commonly pondered subject. Thanks for a great contribution!"
    Ed Price: "This is a great solution with good code formatting and code comments!"
     Windows Server Technical Guru - March 2014  
    Mr X
    How to manage your DC/DNS servers with dynamic IPs in Windows Azure
    JM: "This is an excellent article, however you need to change all instances of the term "on-promise" to "on-premise.""
    JH: "really detailed, very complete with scripts added"
    Richard Mueller: "This might be the best article I have judged. Code formatting could be improved, but otherwise an outstanding contribution."
    Mr X
    How to assign a private Static IP to a Windows Azure VM
    JH: "excellent, concise, good topic"
    Richard Mueller: "Excellent documentation of the use of very new tools to manage IP addresses."
    JM: "Another excellent article, thanks much for your contributions!"
    Mahdi Tehrani
    Customize DST time zone configuration across the forest with GPO
    JM: "This is an excellent article, however you need to change all instances of the term "Daylight Time Saving" to "Daylight Savings Time.""
    JH: "good info, great illustrations and writing"
    Richard Mueller: "Original work for an tricky problem. I think the script should run as a Startup script instead of a Logon script on the clients. A "See Also" section and links would help."
    ----------------- 8< -------------------
    As mentioned above, runners up and their judge feedback were removed from this forum post, to fit into the forum's 60,000 character limit.
    A great big thank you to EVERYONE who contributed an article to last month's competition.
    Read all about THIS month's competition [usually in a stickied post] at the top of this forum, otherwise there is usually a list of forum links for this month's theme/announcement at the bottom of the submission page below:
    http://social.technet.microsoft.com/wiki/contents/articles/23837.technet-guru-contributions-for-april-2014.aspx
    Best regards,
    Pete Laker
    More about the TechNet Guru Awards:
    TechNet Guru Competitions
    #PEJL
    Got any nice code? If you invest time in coding an elegant, novel or impressive answer on MSDN forums, why not copy it over to the one and only
    TechNet Wiki, for future generations to benefit from! You'll never get archived again!
    If you are a member of any user groups, please make sure you list them in the
    Microsoft User Groups Portal. Microsoft are trying to help promote your groups, and collating them here is the first step.

    Congrats to Chandra and Shanky:
     SQL Server General and Database Engine Technical Guru - March 2014  
    chandra sekhar pathivada
    managing database backups across all the instances without maintenance plan
    Samuel Lester: "Chandra, outstanding contribution and information! Your SSIS package handles many of the shortcomings of Maintenance Plans. MPs were originally created to assist DBAs with the more common administrative tasks,
    but as the scale continues to grow across enterprise environments, we're all forced to write our own enhanced versions such as this. Thanks for the addition and please do add to the Gallery if you haven't yet."
    Jinchun Chen: "Nice. It is suggested to add error outputs in the package to handler unexpected errors."
    NN: "Good article. The SSIS solution can use a bit more explanation. Also See Also section is missing"
    DRC: "This is good article, The only this which can be corrected is : ==> This can be achieved using “maintenance Cleanup Task • Maintenance Plan has a control flow item “maintenance Cleanup Task” to delete the old backup files based on
    age of the backup, but it creates the problem when it deletes the full database backups based on n no.of days leaving all the dependent intermediate differential and transaction logs which are useless. "
    Shanky
    Understanding Logging in Tempdb.Is Tempdb re-created or rebuilt after SQL
    Server restart
    NN: "Very good article with an interesting analysis"
    DRC: "This article is good and provides lots of detailed information along with sample query and screenshot. The screenshot of few need few more details (files of model are missing) This article can be broken down into 2 1) understanding tempdb
    recreation 2) Logging in Tempdb 1) understanding tempdb recreation:- This is not concluded properly. The article doesnt talk about the physical files which are recreated even if we delete the tempdb files "
    Samuel Lester: "Shanky, very nice article on the internals of TempDB! It was tough judging this month as both articles were very informative contributions!" 
    Ed Price, Power BI & SQL Server Customer Program Manager (Blog,
    Small Basic,
    Wiki Ninjas,
    Wiki)
    Answer an interesting question?
    Create a wiki article about it!

  • New To Oracle.. Needs Help:: Conversion from SQL Server to Oracle 11g

    I am new to Oracle 11g and badly need the conversion of SQL Server Functions to Oracle.. Sample Pasted Code not working .. end with error.. pls help
    Create Table TempT (ID1 Varchar (10),
    ID2 Varchar (10)
    CREATE OR REPLACE PACKAGE GLOBALPKG
    AS
    TYPE RCT1 IS REF CURSOR;
    TRANCOUNT INTEGER := 0;
    IDENTITY INTEGER;
    END;
    CREATE OR REPLACE FUNCTION fTempT
    i IN VARCHAR2 DEFAULT NULL
    RETURN GLOBALPKG.RCT1
    IS
    REFCURSOR GLOBALPKG.RCT1;
    BEGIN
    OPEN REFCURSOR FOR
    SELECT TT.*
    FROM TempT TT
    WHERE (fTempT.i = ''
    OR TT.ID1 = fTempT.i)
    RETURN REFCURSOR;
    END;
    CREATE OR REPLACE FUNCTION fTempTF
    i IN VARCHAR2 DEFAULT NULL
    RETURN GLOBALPKG.RCT1
    IS
    REFCURSOR GLOBALPKG.RCT1;
    BEGIN
    OPEN REFCURSOR FOR
    SELECT *
    FROM TABLE(fTempT(i))
    RETURN REFCURSOR;
    END;
    LAST FUNCTION ENDs WITH ERROR
    Error(13,7): PL/SQL: ORA-22905: cannot access rows from a non-nested table item

    2. The major purpose is to get a simplest way to create a parameterized function who can return a table like output. 2nd function has no use instead i was testing the result of First Function like thisIf you just want to select from a select, you should use a view not a function.
    1. which program is more help ful for writing and executing queries bcoz after using Query Analyzer of Microsoft It seems difficult to work on SQL Developer.
    sqlplus? If you are having difficulty learning new tools because of an old one you used, probably best to forget the old one and concentrate on learning the new one because it will be different. This goes for the database itself also.
    2. Can DMLs be used within a Function.Yes, you just can't execute the function in another SQL statement if it modifies data and this is a good thing.
    3. Can temporary tables be used within a function.Unfortunately yes, but they shouldn't be unless you are in a slowest application competition.
    5. Each Function which is a Table Function must be accompanied with Type Definitions?? its a bit longer way of doing the things than SQL ServerThat is why it is better to use views instead, is there any reason you want a select that you can select from inside a function?
    SQL Server for last 9 years thats why i refer this toolThat is not in itself a problem, if you try and do what you did in SQLServer in Oracle, that will be a problem though.

  • Conversion From SQL Server to Oracle.. Just New pls someone help

    I am new to Oracle 11g and badly need the conversion of SQL Server Functions to Oracle.. Sample Pasted Code not working .. end with error.. pls help
    Create Table TempT (ID1 Varchar (10),
         ID2 Varchar (10)
    CREATE OR REPLACE PACKAGE GLOBALPKG
    AS
         TYPE RCT1 IS REF CURSOR;
         TRANCOUNT INTEGER := 0;
         IDENTITY INTEGER;
    END;
    CREATE OR REPLACE FUNCTION fTempT
         i IN      VARCHAR2 DEFAULT NULL
    RETURN GLOBALPKG.RCT1
    IS
    REFCURSOR      GLOBALPKG.RCT1;
    BEGIN
    OPEN REFCURSOR FOR
         SELECT TT.*
    FROM TempT TT
    WHERE     (fTempT.i = ''
    OR     TT.ID1 = fTempT.i)
    RETURN REFCURSOR;
    END;
    CREATE OR REPLACE FUNCTION fTempTF
         i IN      VARCHAR2 DEFAULT NULL
    RETURN GLOBALPKG.RCT1
    IS
    REFCURSOR      GLOBALPKG.RCT1;
    BEGIN
    OPEN REFCURSOR FOR
         SELECT *
    FROM TABLE(fTempT(i))
    RETURN REFCURSOR;
    END;
    LAST FUNCTION ENDs WITH ERROR
    Error(13,7): PL/SQL: ORA-22905: cannot access rows from a non-nested table item

    I assume this is a simplified version of a more complex problem, since your second function would not return anything more than the first. If you want to use TABLE on a ref cursor, then you need to do some sort of intermediary transformation, such as using a pipelined function, as in the example in the link below. Also, this does not appear to have anything to do with objects, so should be posted in the SQL and PL/SQL forum instead.
    http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28370/tuning.htm#BABHAABE

  • How to get JDev 10.1.2/ADF working with MS SQL Server Identity Column

    Hello JDevTeam & JDevelopers,
    I want to use JDev/ADF with a MS SQL Server 2005 database that contains tables employing IDENTITY Columns.
    Using JDev/ADF and DBSequence with an Oracle database employing before triggers/sequences accomplishes what I am trying to do except I want to accomplish the same thing using a MSSQL Server 2005 database. Unfortunately I cannot change the database.
    I have been able to select records but I am unable to insert records (due to my lack of knowledge) when using MS/SQL Server Identity Columns with JDev/ADF.
    The following are the steps taken thus far.
    Step1: Create table named test in the 2005 MSSQL Server (see script below).
    Step2: Register 3rd Party JDBC Driver with JDeveloper; Using use Tools/Manage Libraries. Create a new entry in User Libraries with the following;
         Library Name     = Ms2005Jdbc
         Class Path     = C:\dev\Ms2005Jdbc\sqljdbc_1.0\enu\sqljdbc.jar
         (note: Latest TYPE 4 JDBC driver for Microsoft SQL Server 2005 - free at http://msdn.microsoft.com/data/ref/jdbc/)
    Step3:Create New Database Connection;
         Connection Name = testconn1
         Type = Third Party JDBC Driver
         Authentication Username = sa, Password = password, Check Deploy Password
         Connection
              Driver Class = com.microsoft.sqlserver.jdbc.SQLServerDriver     
              Library = Ms2005Jdbc     
              Classpath = C:\dev\Ms2005Jdbc\sqljdbc_1.0\enu
              URL = jdbc:sqlserver://192.168.1.151:1433;instanceName=sqlexpress;databaseName=test
         Test Connection = Success!
    Step5: Create a new application workspace using Web Application default template
    Step6: In Model project, Create new Business Components Diagram.
    Step7: Create new Entity Object. Goto to connections/testconn1, open tables and drag table test onto the diagram.
    Step8: Generate Default Data Model Components by right-clicking on Entity Object. Except all the defaults.
    When I test the Appmodule I select the view object and can scroll through all the records without error. If I try to insert a record, I get JBO-27014: Attribute testid in test is required.
    Going back to the EntityObject I deselect the Mandatory attribute and re-run the test. Now when I try to insert it accepts the value for testname but it does not update the PK testid like it would using an "JDev/ADF/DBSequence/Oracle database/before trigger/sequence" solution.
    Going back to the EntityObject and selecting refresh on insert does not solve this problem either. Changing the URL connection string and adding "SelectMethod=cursor" did not help and changing the SQl Flavor to SQLServer produced errors in the Business Components Browser. I've tried overriding isAttributeChanged() and other things as well.
    I am totally stuck! Can anyone provide a solution?
    Thanks for you help,
    BG...
    Create table named test
    use [testdb]
    go
    set ansi_nulls on
    go
    set quoted_identifier on
    go
    create table [test](
         [testid] [int] identity(0,1) not null,
         [testname] [nvarchar](50) collate sql_latin1_general_cp1_ci_as not null,
    constraint [pk_test] primary key nonclustered
         [testid] asc
    )with (pad_index = off, ignore_dup_key = off) on [primary]
    ) on [primary]

    Figured it out!
    When using the MS SQL Server 2000 Database with the MS JDBC 2000 Driver you specify the SQL Flavor to SQLServer. However setting the SQL Flavor to SQLServer with MS SQL Server 2005 Database and the MS JDBC 2005 Driver will *** fail ***.
    When working with the MS SQL Server 2005 Database and the MS JDBC 2005 Driver you set the SQL Flavor to SQL92 and the Type Map to Java.
    If using a named instance like I am you would specify the URL = jdbc:sqlserver://<db host ip address>:<listening port>;instanceName=<your instance name>;selectMethod=cursor;databaseName=<your database name> (note: leave out the < >)
    The 2005 Driver Class is different then the 2000 and is specified as com.microsoft.sqlserver.jdbc.SQLServerDriver
    Note: In a default MS SQL Server 2005 installation the listening port will change *** everytime *** the host is restarted! You can override this though.
    For the primary key you need to deselect the Mandatory attribute in the EntityObject editor.
    Set Refresh on insert/update = no.
    Set Updateable = never.
    Now my Primary Keys which get their values from the Identity Column are working with ADF in a predictable way.
    Simple enough but I have been away from this stuff for awhile.
    BG...

  • INSERTING DATA INTO A SQL SERVER 2005 TABLE, WHICH HAS A IDENTITY COLUMN

    Hi All,
    I have to insert the data into a SQL SERVER 2005 Database table.
    I am able to insert the data into a normal SQL Server table.
    When I am trying to insert the data into a SQL Server table, which has a identity column (i.e. auto increment column in Oracle) I am getting error saying that can't insert value explicitly when IDENTITY_INSERT is set to OFF.
    Had anybody tried this??
    There are some SRs on this issue, Oracle agreed that it is a bug. I am wondering if there is any workaround from any one of you (refer Insert in MS-SQL database table with IDENTITY COLUMN
    Thanks
    V Kumar

    Even I had raised a SR on this in October 2008. But didn't get any solution for a long time, finally I had removed the identity column from the table. I can't to that now :).
    I am using 10.1.3.3.0 and MS SQL SERVER 2005, They said it is working for MS SQL SERVER TABLE, if the identity column is not a primary key and asked me to refer to note 744735.1.
    I had followed that note, but still it is not working for me.
    But my requirement is it should work for a MS SQL SERVER 2005 table, which has identity column as primary key.
    Thanks
    V Kumar

  • Is there any way to activate the keep identity setting when using a Transfer SQL Server Object Task?

    Is there any way to add the "Keep Identity" option to the tables selected for transfer in a Transfer SQL Server Object Task?  It seems that would be very useful, yet I can't find an easily available setting for it.  I would prefer to
    accomplish this within the Transfer SQL Server Object Task since it can copy any new fields added to the source tables, as opposed to having to rebuild a custom Data Flow Task any time a table structure is altered.  I thought setting "CopyPrimaryKeys"
    to True would do the trick, but I found that only ensures that the column settings are transferred; when the transfer happens, the destination id column is populated based on the specified seed and increment value, not what's actually in the source table. 
    I'd like to point out that replication isn't really an option here. This is a package that runs a few times a day to keep some data on our website up to date with data in our protected corporate environment.

    IIRW there is FastLoadKeepIdentity specifies
    whether to keep an identity in OLEDB destination 
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • (new?) performance problem using jDriver after a Sql Server 6.5 to 2000 conversion

    Hi,
    This is similar - yet different - to a few of the old postings about performance
    problems with using jdbc drivers against Sql Server 7 & 2000.
    Here's the situation:
    I am running a standalone java application on a Solaris box using BEA's jdbc driver
    to connect to a Sql Server database on another network. The application retrieves
    data from the database through joins on several tables for approximately 40,000
    unique ids. It then processes all of this data and produces a file. We tuned
    the app so that the execution time for a single run through the application was
    24 minutes running against Sql Server 6.5 with BEA's jdbc driver. After performing
    a DBMS conversion to upgrade it to Sql Server 2000 I switched the jDriver to the
    Sql Server 2000 version. I ran the app and got an alarming execution time of
    5hrs 32 min. After some research, I found the problem with unicode and nvarchar/varchar
    and set the "useVarChars" property to "true" on the driver. The execution time
    for a single run through the application is now 56 minutes.
    56 minutes compared to 5 1/2 hrs is an amazing improvement. However, it is still
    over twice the execution time that I was seeing against the 6.5 database. Theoretically,
    I should be able to switch out my jdbc driver and the DBMS conversion should be
    invisible to my application. That would also mean that I should be seeing the
    same execution times with both versions of the DBMS. Has anybody else seen a
    simlar situation? Are there any other settings or fixes that I can put into place
    to get my performance back down to what I was seeing with 6.5? I would rather
    not have to go through and perform another round of performance tuning after having
    already done this when the app was originally built.
    thanks,
    mike

    Mike wrote:
    Joe,
    This was actually my next step. I replaced the BEA driver with
    the MS driver and let it run through with out making any
    configuration changes, just to see what happened. I got an
    execution time of about 7 1/2 hrs (which was shocking). So,
    (comparing apples to apples) while leaving the default unicode
    property on, BEA ran faster than MS, 5 1/2 hrs to 7 1/2 hrs.
    I then set the 'SendStringParametersAsUnicode' to 'false' on the
    MS driver and ran another test. This time the application
    executed in just over 24 minutes. The actual runtime was 24 min
    16 sec, which is still ever so slightly above the actual runtime
    against SS 6.5 which was 23 min 35 sec, but is twice as fast as the
    56 minutes that BEA's driver was giving me.
    I think that this is very interesting. I checked to make sure that
    there were no outside factors that may have been influencing the
    runtimes in either case, and there were none. Just to make sure,
    I ran each driver again and got the same results. It sounds like
    there are no known issues regarding this?
    We have people looking into things on the DBMS side and I'm still
    looking into things on my end, but so far none of us have found
    anything. We'd like to continue using BEA's driver for the
    support and the fact that we use Weblogic Server for all of our
    online applications, but this new data might mean that I have to
    switch drivers for this particular application.Thanks. No, there is no known issue, and if you put a packet sniffer
    between the client and DBMS, you will probably not see any appreciable
    difference in the content of the SQL sent be either driver. My suspicion is
    that it involves the historical backward compatibility built in to the DBMS.
    It must still handle several iterations of older applications, speaking obsolete
    versions of the DBMS protocol, and expecting different DBMS behavior!
    Our driver presents itself as a SQL7-level application, and may well be treated
    differently than a newer one. This may include different query processing.
    Because our driver is deprecated, it is unlikely that it will be changed in
    future. We will certainly support you using the MS driver, and if you look
    in the MS JDBC newsgroup, you'll see more answers from BEA folks than
    from MS people!
    Joe
    >
    >
    Mike
    The next test you should do, to isolate the issue, is to try another
    JDBC driver.
    MS provides a type-4 driver now, for free. If it is significantly faster,
    it would be
    interesting. However, it would still not isolate the problem, because
    we still would
    need to know what query plan is created by the DBMS, and why.
    Joe Weinstein at BEA
    PS: I can only tell you that our driver has not changed in it's semantic
    function.
    It essentially send SQL to the DBMS. It doesn't alter it.

  • SAP query error - 1). [Microsoft][SQL Server Native Client 10.0][SQL Server]Conversion failed when converting date and/or time from character string.  'Received Alerts' (OAIB)

    SAP query error - 1). [Microsoft][SQL Server Native Client 10.0][SQL Server]Conversion failed when converting date and/or time from character string.  'Received Alerts' (OAIB)
    SELECT    
    CASE WHEN T0.DocStatus = 'O' THEN 'OPEN'
    WHEN T0.DocStatus = 'C' THEN 'CLOSED'  END  AS 'Document Status',
    T0.DocDate AS 'Posting Date',
    T0.DocNum AS 'Doc.No',
    T0.NumAtCard,
    T0.TransId AS 'Trans. No.',
    T0.Comments AS 'Remarks',
    T0.CardCode AS 'Offset Acct',
    T0.CardName AS 'Offset Acct Name',
    sum(T0.DocTotal) + (T0.WTSum) as 'DocTotal',
    T3.DueDate AS 'Cheque Date',
    T3.CheckSum AS 'Amount'
    FROM         ODPO AS T0 LEFT OUTER JOIN
                          VPM2 AS T1 ON T0.ObjType = T1.InvType AND T0.DocEntry = T1.DocEntry LEFT OUTER JOIN
         OVPM AS T2 ON T2.DocEntry = T1.DocNum LEFT OUTER JOIN
                          VPM1 AS T3 ON T2.DocEntry = T3.DocNum
    where T0.DocDate>='[%0]' and T0.DocDate<='[%1]'

    Hi,
    Try this:
    SELECT   
    CASE WHEN T0.DocStatus = 'O' THEN 'OPEN'
    WHEN T0.DocStatus = 'C' THEN 'CLOSED'  END  AS 'Document Status',
    T0.DocDate AS 'Posting Date',
    T0.DocNum AS 'Doc.No',
    T0.NumAtCard,
    T0.TransId AS 'Trans. No.',
    T0.Comments AS 'Remarks',
    T0.CardCode AS 'Offset Acct',
    T0.CardName AS 'Offset Acct Name',
    sum(T0.DocTotal) + (T0.WTSum) as 'DocTotal',
    T3.DueDate AS 'Cheque Date',
    T3.CheckSum AS 'Amount'
    FROM         ODPO  T0 LEFT OUTER JOIN
                          VPM2  T1 ON T0.ObjType = T1.InvType AND T0.DocEntry = T1.DocEntry
    LEFT OUTER JOIN
         OVPM  T2 ON T2.DocEntry = T1.DocNum LEFT OUTER JOIN
                          VPM1  T3 ON T2.DocEntry = T3.DocNum
    where T0.DocDate >= '[%0]' and T0.DocDate <='[%1]'
    group by T0.DocStatus,T0.DocDate ,
    T0.DocNum ,
    T0.NumAtCard,
    T0.TransId ,
    T0.Comments ,
    T0.CardCode,
    T0.CardName ,
    T0.WTSum ,
    T3.DueDate ,
    T3.CheckSum
    Thanks & Regards,
    Nagarajan

  • Passing SQL Server identity attributes values into adf entity objects

    Hi all.
    I'm using Jdeveloper 10g for developing an ADF Swing application based on MS SQL Server DB.
    Does anyone know if it is possible to pass SQL Server identity attributes values into the correspondent attrributes of adf entity objects, like we do with Oracle DB Sequence.
    The problem is that i should somhow implement cascade deleting of detail view objects, so i should use the composition association. But since i cant fill the primary key attribute with appropriate value (that is actually a ms sql server db sequence value) i always get
    the following exception: oracle.jbo.InvalidOwnerException: JBO-25030 as i try to create a new pair of master/detail objects.
    Thanks in advance.
    Alex.

    The approach is good. but i still dont understand how i can address the sql server db sequence (identity field) programmatically...
    The code offered
    SequenceImpl sequence = new SequenceImpl("PRODUCTS_SEQ",getDBTransaction());
    setProdId(sequence.getSequenceNumber());
    generates something like this:
    select deq_name.nextval from dual
    but this syntax works for oracle only... and not for sql server...
    Edited by: Timin on Mar 26, 2009 6:34 AM
    Edited by: Timin on Mar 26, 2009 10:25 AM

  • MySQL to SQL Server Conversion Tools

    Anyone know of any FREE database conversion tools?

    It's not a tool, but you might find Microsoft's documentation helpful.  You might also post this question in a Microsoft SQL Server specific forum.
    "Migrating to SQL Server 2008"
    http://www.microsoft.com/Sqlserver/2008/en/us/migration.aspx

  • MS SQL Server 2014: Error inserting into Temp table with index and identity field

    In this thread, I mentioned a problem with SQL Server 2014:
    SQL Server 2014: Bug with IDENTITY INSERT ON
    The question was answered, it is a bug. To keep you informed on this issue, I open this discussion.
    Problem:
    The code below works perfectly fine on MS SQL Server 2008 R2 and MS SQL Server 2012, but gives an error every second time the proc is executed on MS SQL Server 2014. If I do not define any index on the temp table, the problem disappears. Defining the index
    after the insert, does not help.
    SET NOCOUNT ON
    GO
    IF EXISTS (SELECT 1 FROM sys.procedures WHERE name = 'usp_Test') DROP PROC dbo.usp_Test;
    GO
    CREATE PROC dbo.usp_Test AS
    BEGIN
    SET NOCOUNT ON
    CREATE TABLE #Source(ID integer NOT NULL);
    INSERT INTO #Source VALUES (1), (2), (3);
    CREATE TABLE #Dest (ID integer IDENTITY(1,1) NOT NULL);
    CREATE INDEX #IDX_Dest ON #Dest (ID);
    PRINT 'Check if the insert might cause an identity crisis';
    SELECT 'Source' AS SourceTable, * FROM #Source;
    SELECT 'Destination' AS DestTable, * FROM #Dest;
    SET IDENTITY_INSERT #Dest ON;
    PRINT 'Do the insert';
    INSERT INTO #Dest (ID) SELECT ID FROM #Source;
    PRINT 'Insert ready';
    SET IDENTITY_INSERT #Dest OFF;
    SELECT * FROM #Dest;
    DROP TABLE #Source;
    DROP TABLE #Dest;
    END;
    GO
    PRINT 'First execution of the proc, everything OK';
    EXEC dbo.usp_Test;
    PRINT '';
    PRINT 'Second execution of the proc, the insert fails.';
    PRINT 'Removing the index #IDX_Dest causes the error to disappear.';
    EXEC dbo.usp_Test;
    GO
    DROP PROC dbo.usp_Test;
    GO

    There is some progress. Communication from a former Microsoft employee tells us this:
    Shivendra Vishal
    Engineer at Microsoft
    I am no longer with MS, and I do not have code access, however from the public symbols, I could make out following:
    sqlmin!SetidentI2I4+0x1f3:
    000007fe`f4d865d3 488b10 mov rdx,qword ptr [rax] ds:00000000`00000000=????????????????
    ExceptionAddress: 000007fef4d865d3 (sqlmin!SetidentI2I4+0x00000000000001f3)
    ExceptionCode: c0000005 (Access violation)
    ExceptionFlags: 00000000
    NumberParameters: 2
    Parameter[0]: 0000000000000000
    Parameter[1]: 0000000000000000
    Attempt to read from address 0000000000000000
    This is a read AV and from registers it is clear that we were trying to move the value of location pointed by qword of register rax which is not valid:
    rax=0000000000000000 rbx=0000000000000038 rcx=0000000000001030
    rdx=0000000000000006 rsi=00000001f55def98 rdi=00000000106fd070
    rip=000007fef4d865d3 rsp=00000000106fcf40 rbp=00000000106fcfe9
    r8=0000000000000000 r9=00000001f55def60 r10=00000001f55defa0
    r11=00000000106fcd20 r12=0000000000000000 r13=0000000000000002
    r14=00000001f49c3860 r15=00000001f58c0040
    iopl=0 nv up ei pl nz na po nc
    cs=0033 ss=002b ds=002b es=002b fs=0053 gs=002b efl=00010206
    The stack is:
    # Child-SP RetAddr Call Site
    00 00000000`106fcf40 000007fe`f30c1437 sqlmin!SetidentI2I4+0x1f3
    01 00000000`106fd050 000007fe`f474e7ce sqlTsEs!CEsExec::GeneralEval4+0xe7
    02 00000000`106fd120 000007fe`f470e6ef sqlmin!CQScanUpdateNew::GetRow+0x43d
    03 00000000`106fd1d0 000007fe`f08ff517 sqlmin!CQueryScan::GetRow+0x81
    04 00000000`106fd200 000007fe`f091cebe sqllang!CXStmtQuery::ErsqExecuteQuery+0x36d
    05 00000000`106fd390 000007fe`f091ccb9 sqllang!CXStmtDML::XretDMLExecute+0x2ee
    06 00000000`106fd480 000007fe`f08fa058 sqllang!CXStmtDML::XretExecute+0xad
    07 00000000`106fd4b0 000007fe`f08fb66b sqllang!CMsqlExecContext::ExecuteStmts<1,1>+0x427
    08 00000000`106fd5f0 000007fe`f08fac2e sqllang!CMsqlExecContext::FExecute+0xa33
    09 00000000`106fd7e0 000007fe`f152cfaa sqllang!CSQLSource::Execute+0x86c
    0a 00000000`106fd9b0 000007fe`f152c9e8 sqllang!CStmtExecProc::XretLocalExec+0x25a
    0b 00000000`106fda30 000007fe`f152a1d8 sqllang!CStmtExecProc::XretExecExecute+0x4e8
    0c 00000000`106fe1e0 000007fe`f08fa058 sqllang!CXStmtExecProc::XretExecute+0x38
    0d 00000000`106fe220 000007fe`f08fb66b sqllang!CMsqlExecContext::ExecuteStmts<1,1>+0x427
    0e 00000000`106fe360 000007fe`f08fac2e sqllang!CMsqlExecContext::FExecute+0xa33
    0f 00000000`106fe550 000007fe`f0902267 sqllang!CSQLSource::Execute+0x86c
    10 00000000`106fe720 000007fe`f0909087 sqllang!process_request+0xa57
    11 00000000`106feee0 000007fe`f2bf49d0 sqllang!process_commands+0x4a3
    12 00000000`106ff200 000007fe`f2bf47b4 sqldk!SOS_Task::Param::Execute+0x21e
    13 00000000`106ff800 000007fe`f2bf45b6 sqldk!SOS_Scheduler::RunTask+0xa8
    14 00000000`106ff870 000007fe`f2c136ff sqldk!SOS_Scheduler::ProcessTasks+0x279
    15 00000000`106ff8f0 000007fe`f2c138f0 sqldk!SchedulerManager::WorkerEntryPoint+0x24c
    16 00000000`106ff990 000007fe`f2c13246 sqldk!SystemThread::RunWorker+0x8f
    17 00000000`106ff9c0 000007fe`f2c13558 sqldk!SystemThreadDispatcher::ProcessWorker+0x3ab
    18 00000000`106ffa70 00000000`775d59ed sqldk!SchedulerManager::ThreadEntryPoint+0x226
    19 00000000`106ffb10 00000000`7780c541 kernel32!BaseThreadInitThunk+0xd
    1a 00000000`106ffb40 00000000`00000000 ntdll!RtlUserThreadStart+0x21
    Unassembling the function:
    000007fe`f4d8658e 4c8b10 mov r10,qword ptr [rax]
    000007fe`f4d86591 4533e4 xor r12d,r12d
    000007fe`f4d86594 410fb7d5 movzx edx,r13w
    000007fe`f4d86598 4533c9 xor r9d,r9d
    000007fe`f4d8659b 4533c0 xor r8d,r8d
    000007fe`f4d8659e 488bc8 mov rcx,rax
    000007fe`f4d865a1 4489642420 mov dword ptr [rsp+20h],r12d
    000007fe`f4d865a6 41ff5230 call qword ptr [r10+30h]
    000007fe`f4d865aa 8b5597 mov edx,dword ptr [rbp-69h]
    000007fe`f4d865ad 4c8b10 mov r10,qword ptr [rax]
    000007fe`f4d865b0 4489642438 mov dword ptr [rsp+38h],r12d
    000007fe`f4d865b5 4489642430 mov dword ptr [rsp+30h],r12d
    000007fe`f4d865ba 458d442401 lea r8d,[r12+1]
    000007fe`f4d865bf 4533c9 xor r9d,r9d
    000007fe`f4d865c2 488bc8 mov rcx,rax
    000007fe`f4d865c5 c644242801 mov byte ptr [rsp+28h],1
    000007fe`f4d865ca 4488642420 mov byte ptr [rsp+20h],r12b
    000007fe`f4d865cf 41ff5250 call qword ptr [r10+50h]
    000007fe`f4d865d3 488b10 mov rdx,qword ptr [rax] <=================== AV happened over here
    000007fe`f4d865d6 488bc8 mov rcx,rax
    000007fe`f4d865d9 4c8bf0 mov r14,rax
    000007fe`f4d865dc ff5268 call qword ptr [rdx+68h]
    000007fe`f4d865df 488d55e7 lea rdx,[rbp-19h]
    000007fe`f4d865e3 4c8b00 mov r8,qword ptr [rax]
    000007fe`f4d865e6 488bc8 mov rcx,rax
    000007fe`f4d865e9 41ff5010 call qword ptr [r8+10h]
    000007fe`f4d865ed f6450a04 test byte ptr [rbp+0Ah],4
    I remember few issues with scan2ident function, I am not sure if they have fixed it however it appears that this is intoduced to SQL 2014 and we need help from MS to get this resolved as it needs code analysis.
    It is not getting simulated for other versions of SQL apart from SQL 2014.
    Also to add, interestingly, the value of rax is not visibly changed and it was successfully passed on to rcx, which has a valid value, so something should have changed the value of rax inside call to function using call qword ptr [r10+50h], and looking at this
    it appears that it might be a list of functions and we are going at particular offset [50h]. So, bottom line is that the call to function qword ptr [r10+50h], should be changing something in rax, and debugging/analyzing this code might give us some more idea.

Maybe you are looking for

  • HT1349 Why won't "show duplicates" show up in either my File or Edit menus?  And, why does my entire library keep getting duplicated?

    I have a new computer and I'm trying to reload my library and my playlists.  I also have a new iPhone 5 and I'm trying to load that too.  I'm getting duplicates of everything in my library.  When I try to find the "show duplicates" tab in my File men

  • How to execute the data in the form when the data is already avaliable

    Hi, I am working with forms 6i. I have a problem while executing the data in the form Actually, the data is already present in the form. But when i run the form, the data is not displayed. can anyone please help me how to execute the data. below is t

  • I can't connect my mobile x6-00 to my computer thr...

    When I connect it vi suite keep telling me that USB  drivers are being installed on your computer so I left it for 24 hours the computer is and when I woke up the next day still installing I think that some drivers cannot take that long Solved! Go to

  • Problem with logical or

    hi friends i am using OR in a select statement like this : select single KAWRT from KONV into var2 where KNUMV = var1 and STUNR = 65 or STUNR = 60 . but what i want is that the result for this should be calculated as KNUMV =var1 and (STUNR = 65 or ST

  • System crash when use underline

    Hi. It seems to have bug in the TextLine creation when use underline... Look: for(var iIndex:int = 0; iIndex<10000; iIndex++){      var strTest: String = '<flow:TextFlow paddingTop="3" paddingLeft="3" whiteSpaceCollapse="preserve" xmlns:flow="http://