Calculate the fastest path between 2 nodes with the data model for the Oracle network

Hi all,

I have Oracle 10 g 2.

My problem is the following:

I created a network named ITALIA_NET in the data model for the Oracle network.
The table of links of this network is named: ITALIA_NET_LINK$.
The table of the nodes of this network is named: ITALIA_NET_NODE$.

The table ITALIA_NET_LINK$ contains a field named COST that contains links (in meters) lengths.

I've already calculated the SHORTEST PATH between two nodes of the network, by using the method of shortestPath() (using the Java API) as shown on "Pro Oracle Spatial for Oracle Database 11 g" manual. Infact, this method makes reference to the COST field for $ ITALIA_NET_LINK to make this calculation.

Now, I want to calculate the FASTER PATH between two nodes of the network. I have the links (in hours) travel time to make this calculation.

My idea is to create a new field in ITALIA_NET_LINK$ named Cost2 containing the travel time from the links and then do the math by using the shorthestPath() method, referring to the Cost2 field to $ ITALIA_NET_LINK COST field instead.
By default, I know that the shorthestPath() method returns the COST field for $ ITALIA_NET_LINK. Is possible to change this setting and do that this method refers to the Cost2 field?

In the alternative, is another way for the calculation of the fastest way?
I want to leave the creation of another network as last solution, because I will have other costs of field (Cost3, cos4t,...)

Thank you much in advance.

Your approach is good. You will have two networks and you can read them in memory and analyze of shortest path. The shortestPath method is static for the class of NetworkManager. You can use the same method for both networks, once they are read into memory.

...
read the network with time as cost of link
NetTime network = NetworkManager.readNetwork (dbConnection, 'ITALIA_NET_TIME');
read the network length as cost of link
Network netLength = NetworkManager.readNetwork (dbConnection, 'ITALIA_NET_LENGTH');

calculate the quickest way
PathTime path = NetworkManager.shortestPath (netTime, startNodeID, endNodeID);
calculate the shortest path
PathLength path = NetworkManager.shortestPath (netLength, startNodeID, endNodeID);
...

In the future, if you upgrade to 11g, network data model provides a load on demand (LOD) API that loads only the scores of necessary network in memory during the analysis. This command removes the restriction of the memory of the 10g (in memory API you use) API. API of LOD can handle very large networks and offers more features analysis and modeling capabilities.

The following link contains the tutorial of NDM LOD API ready for download. Just for your information.
https://spatial.SampleCode.Oracle.com/servlets/ProjectProcess?PageID=0Zl7oV

Kind regards
Jack

Tags: Database

Similar Questions

  • books on the oracle network configuration?

    Salvation;

    I'm looking for books about the oracle network configuration details. I tried oracle press, O'Reillys, Amazon and google; However, I only found books specific to oracle net that bear a date entirely. It seems that General database management books have chapters on the configuration of the network, however.

    At the configuration of the network under oracle 10 g + arrived at the point where the comprehensive books on the subject are not worth the cost?

    I was hoping to find information on the syntax of different files, which can go in the and how to solve problems of connectivity - preferably in a place so much when I'm faced with a problem, I don't have to go hunting for more information. This and he is studying a whole lot easier.

    Any info is greatly appreciated.

    Thank you.

    Doug O'Leary

    Just go through this

    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14196/network001.htm#sthref174

    http://download.Oracle.com/docs/CD/B19306_01/network.102/b14212/TOC.htm

    Published by: CKPT on July 19, 2010 19:58

  • Use the stored procedure to create the data model for the bi publisher report

    Hi all

    Can we use stored procedure to create the data model for BI Publisher reports? I did find an example by using the stored procedure to complete the data model in the bi publisher report.

    Thank you

    Virat

    Check out these links

    BI publisher to use the stored procedure
    Re: Stored procedures and dynamic columns
    Re: Is it possible to use stored procedures in BI Publisher GUI?
    Re: PL/SQL stored w / model XML?

    If brand pls help

  • "Deploy the data model for LCD screens" period

    Hello

    My Jboss is time-consuming while deploying the data model for LCD screens and it's initially Flash Builder 4 to display the error "Read Timed" out. How can I increase this timeout value?

    Thank you

    Houda

    Hello

    Please follow the steps below and see if it helps:

    1. in your Flash Builder click on the item in window menu, click on Preferences

    2. in the Preferences window, select Adobe-> RDS configuration

    3. Select your configured server and change/set Timeout

    I hope this helps.

  • All paths between 2 nodes

    Hello

    Can you get it someone please let me know how can I achieve this?

    I want to know all the paths between A Source node and the node of Destination B.

    I donot want the shortest way but all paths between the 2 nodes.

    Also I donot have no weight/cost by any path. (The graph is a directed graph)

    Kind regards
    Pantxo

    Hello

    Maybe this:

    Scott@my11g SQL>l
      1  with links(n1,n2) as (
      2  select 'A','B' from dual
      3  union all select 'A','C' from dual
      4  union all select 'B','C' from dual
      5  union all select 'B','D' from dual
      6  union all select 'D','G' from dual
      7  union all select 'C','G' from dual
      8  union all select 'D','I' from dual
      9  union all select 'C','E' from dual
     10  union all select 'E','F' from dual
     11  union all select 'F','G' from dual
     12  union all select 'F','H' from dual
     13  )
     14  select pth
     15  from (
     16  select connect_by_root(n1) || sys_connect_by_path(n2,'>') pth ,n2
     17  from links
     18  start with n1='A'
     19  connect by nocycle prior n2=n1
     20  )
     21* where n2='G'
    Scott@my11g SQL>/
    
    PTH
    ----------------------------------------
    A>B>C>E>F>G
    A>B>C>G
    A>B>D>G
    A>C>E>F>G
    A>C>G
    
  • Data modeling for a small database tutorial - understand the part 'Creating relationships between entities'

    I'm trying to understand and make use of Tutorial: modeling of data for a small database

    In this tutorial, I'm supposed to make Entity Transactions containing two attributes that designates the bosses (patron_id) and Books (book_id) (2.1.4) entities

    Later, I add two one-to-many relationships that attributes mentioned twice in the entity of Transactions (patron_id1 and book_id1). (2.1.5)

    So here are my questions: what is the purpose of creating attributed to point 2.1.4 if they are then reproduced in paragraph 2.1.5?

    If she could be crucial, I use Oracle SQL Developer Data Modeler Version 4.0.0.825 Build 825 on jdk1.7.0_25.

    Bonus question: how to turn attributes types on the logical diagram? I can't find the option anywhere...

    I would be really grateful for each answer and all the stuff!

    Looking at the documentation for version 2.  I checked 3.3 and 4.0 EA3 and corrected tutorial you can download the latest version and use this documentation.

  • Need help to create "no data available" message with multiple data models

    I tried several ways to have a "no documents found" generic message based on certain criteria however it doesn't seem to work. I have two models of data, each only show the information if something is created, deleted, etc. in a certain number of days. If nothing happens for these days, I don't want to report table to display, only a message saying something like "no record".

    I tried the following different types:
    <?if:count(ROW/opened_last_7_days) = 0?>There weren’t any projects created within the past week.<?end if?>
    <?if:count(ROW/opened_last_7_days) > 0?> (report table) <?end if?>
    <?if:count(DATA/opened_last_7_days) = 0?>There weren’t any projects created within the past week.<?end if?>
    <?if:count(DATA/opened_last_7_days) > 0?> (report table) <?end if?>
    The names of the two data models are:
    opened_last_7_days
    closed_last_7_days

    I be recover anything on the page or both records not found and the table appear.

    Sql queries work fine, I get all the answer I need.

    Any help would be appreciated. Thank you.

    Take a look at this: http://winrichman.blogspot.com/2009/05/no-data-found.html

    Thank you!

  • Find paths between two nodes using SQL sort by cost

    Hi gurus,

    I want to find all paths from the source node to the target node that will be sorted by the cost. I don't know if it was possible with the SQL statement. How to start with this query? The script to create the tables and data are given below:

    ------------------------------------------------------------------------------------------------------------------
    create table of nodes (nodeId int Primary Key, nodeName varchar (50));

    create paths of table (pathId int Primary Key, int fromNodeId, int toNodeId, int cost);

    insert into a values (1, 'ISL') nodes;
    insert into a values (2, "LHR") nodes;
    insert into a values (3, 'HYD') nodes;
    insert into a values (4, 'FLS') nodes;
    insert into a values (5, 'MUL') nodes;
    insert into a values (6, "KHI") nodes;
    insert into a values (7, 'QT') nodes;

    insert into values of paths (1,1,3,20);
    insert into values of paths (2,1,5,10);
    insert into values of paths (3,1,7,80);
    insert into values of paths (4,2,4,10);
    insert into values of paths (5,3,4,40);
    insert into values of paths (6,3,5,20);
    insert into values of paths (7,3,6,10);
    insert into values of paths (8,6,7,30);
    insert into values of paths (9,6,5,30);
    insert into values of paths (10,6,3,10);
    insert into values of paths (11,7,2,20);
    insert into values of paths (12,5,4,40);
    insert into values of paths (13,5,7,40);

    ----------------------------------------------------------------------------------------------------------------------------------
    Assume that the source = ISL and QT= target, there are different paths to QT ISL:

    Path relative cost DSB #.
    ==== ================================= =================
    1 ISL-> Multimedia-> QT 50
    2 ISL->->-> QT 60 KHI HYD
    3 ISL-> QT 80
    4 ISL-> HYD-> Multimedia-> QT 80
    5 ISL-> HYD at KHI-> Multimedia-> QT 100

    This gives us all possible paths, sorted by price.

    No indication or help will be appreciated.

    Thanks in advance and best regards

    Bilal

    Published by: naive2Oracle on February 11, 2011 09:59
    select  ltrim(sys_connect_by_path(nodeName,'->'),'->') path,
            extractvalue(dbms_xmlgen.getXMLtype('select '|| sys_connect_by_path(cost,'+') ||' cost from dual'),'/ROWSET/ROW/COST') - cost cost
      from  paths p,
            nodes n
      where p.fromNodeId = n.nodeId
        and nodeName = 'QT'
      start with nodeName = 'ISL'
      connect by nocycle fromNodeId = prior toNodeId
                     and prior nodeName != 'QT'
        order by cost
    /
    
    PATH                                                              COST
    -------------------------------------------------- -------------------
    ISL->MUL->QT                                                        50
    ISL->HYD->KHI->QT                                                   60
    ISL->HYD->MUL->QT                                                   80
    ISL->QT                                                             80
    ISL->HYD->KHI->HYD->MUL->QT                                        100
    ISL->HYD->KHI->MUL->QT                                             100
    
    6 rows selected.
    
    SQL> 
    

    SY.

  • Hierarchical Oracle query help needed - path between the crux of two brothers and sisters

    I want to find the path between two nodes of oracle hierarchical Table.

    Consider the following case-
    NodeId - ParentId
    =============
    1 > > > > > > 0
    2 > > > > > > 1
    3 > > > > > > 2
    4 > > > > > > 3
    5 > > > > > > 0
    6 > > > > > > 5
    Here I want to query the database table that if there is a path between nodes 3 and 5?
    The previous query you provided work upwards to the root node.

    Here is my expected result, 3-> 2-> 1-> 0-> 5

    Yet once if I have a query in the table to get the path between 1 and 3, I want to get out of the way - next
    1-> 2-> 3

    Therefore, the query works in both cases. Where ADI root can act as an intermediate or no node.

    Can you please guide me how I can get it?

    Thank you.

    Hello

    user13276471 wrote:
    I want to find the path between two nodes of oracle hierarchical Table.

    Consider the following case-
    NodeId - ParentId
    =============
    1 >>>>>> 0
    2 >>>>>> 1
    3 >>>>>> 2
    4 >>>>>> 3
    5 >>>>>> 0
    6 >>>>>> 5
    Here I want to query the database table that if there is a path between nodes 3 and 5?
    The previous query

    What application is this? If you're referering to another thread, then post a link, such as {message identifier: = 10769125}

    you provided work upwards to the root node.

    Here is my expected result, 3--> 2--> 1--> 0--> 5

    Yet once if I have a query in the table to get the path between 1 and 3, I want to get out of the way - next
    1--> 2--> 3

    Therefore, the query works in both cases. Where ADI root can act as an intermediate or no node.

    Can you please guide me how I can get it?

    I think you want something like this:

    WITH     bottom_up_from_src    AS
    (
         SELECT     nodeid
         ,     parentid
         FROM     table_x
         START WITH     nodeid      = :src_nodeid
         CONNECT BY     nodeid   = PRIOR parentid
    )
    ,     bottom_up_from_dst     AS
    (
         SELECT     *
         FROM     bottom_up_from_src
        UNION ALL
         SELECT     parentid     AS nodeid
         ,     nodeid          AS parentid
         FROM     table_x
         WHERE     nodeid     NOT IN (
                                          SELECT  nodeid
                                   FROM    bottom_up_from_src
                                      )
         START WITH     nodeid        = :dst_nodeid
         CONNECT BY     nodeid        = PRIOR parentid
    )
    SELECT      :src_nodeid || SYS_CONNECT_BY_PATH (parentid, '-->')     AS display_path
    FROM       bottom_up_from_dst
    WHERE       parentid     = :dst_nodeid
    START WITH  nodeid     = :src_nodeid
    CONNECT BY  nodeid     = PRIOR parentid
    ;
    

    This will show how you can get it from: src_nodeid at dst_nodeid, moving to the top or to the bottom of a hierarchy at a time step. This will work regardless of the fact that


    • : src_nodeid is the ancestor of the: dst_nodeid, or
    • : src_nodeid is a descendant of: dst_nodeid, or
    • both: src_nodeid and: dst_nodeid are the descendants of another node (e.g. 0).

    I hope that answers your question.
    If not, post a small example data (CREATE TABLE and only relevant columns, INSERT statements) and also publish outcomes from these data.
    Explain, using specific examples, how you get these results from these data.
    Always say what version of Oracle you are using (for example, 11.2.0.2.0). It is always important, but particularly so with CONNECT BY queries, because each version since Oracle 7 had significant improvements in this area.
    See the FAQ forum {message identifier: = 9360002}

  • Context: Target cannot find the node with id 33

    Hello

    In my qml file, I used the spreadsheet component. When you click the button, I tried to call the RPC function that calls the web service and according to the response from the service web I have to redirect to special qml. But while qml opening of the CPP, I get the following errors.

    libpng warning: iCCP: known incorrect sRGB profile
    Context: Failed to find target node with id  33
    

    For a moment, I am able to redirect to special qml but control returned to previous qml.

    I am not able to understand why this error came? When I run my application a day before it was working fine. When I reset the device and upgrade the operating system 10.2 I get this error.

    Here is my code in the PRC:

           QmlDocument *qml = QmlDocument::create("asset:///backgroundProcessImageFile.qml");
        qml->setContextProperty("RoamAssist", this);
        AbstractPane *root = qml->createRootObject();
        globalApp->setScene(root);
    

    Hey... my problem is solved...

    Insted to create the user interface using the sheet I just create new page and open it using NavigationPane.

    I still don't know if this issue is due to the component of the roadmap or due to the os version upgradation.

  • vMotion between two hosts with different version?


    Hello

    Can I vMotion VM between two hosts with different version? For example, a virtual machine of esxi 6.0 5.5 esxi and esxi esxi 6.0 5.5 vMotion.

    Thank you.

    Yes, it will avoid you to move.

  • I can create forms in the designer, but when I use a data model, I can't interact with the form

    In LiveCycle Designer ES2 I can create a form and then preview and interact with the form.

    This guess I just build objects by dragging the pieces pre-made object on the form (for example, text field) - which I can name, wrap in subforms something - I can add actions and all is well.  When I preview the PDF, I can enter data in the fields, click on the radio buttons, making things appear that everything is great.

    But LC ES2 is based on the data driven development model by, so in my case I need a form guide as well as the form - so it's better to have a model of data created in the first place - and then create the form based on the data model - then build guide form based on the data model - it is also a good idea, and I'm cool with that.

    My problem is that when I'm building a data model (just for a quick and dirty development demo, not associated with services back-end or databases) and I create the form based on the data model - I can't interact with all objects in the preview pane form - further when I launch the workspace and call my process that contains the form - I even can't interact with the form.

    What I am doing wrong?

    Summons - I can create a form and interact with it - but If I start with a data model and generate the form based on that - I can't interact with the form (option buttons click-I can not enter data in form fields - etc) what causes this?  What should I do to use a data model and be able to create an interactive form? >

    Does anyone know what causes this problem?  It's driving me crazy.

    Thank you-

    Ben

    You do not hurt anuthing. It works as advertised. When you generate a Guide and work with a fml data model designer you will only create a static non-fillable PDF file. This is because when you import the model in the designer of the model must be turned in a schema. The schema may not represent constraints and validations can be encoded in the model. The only thing that can be maintained is the structure, so Designer forbids you to buidl an interactive form.

    If you know what you're doing, you could take the data it is generated from the Guide and merge on a XDP template file that you create (unless he models in a first time - you can use the sample XML data as a starting point) using LC forms. Edowmside, is that if there are constraints and rules you would have to code them in the model as well. That's the way it is now there, but it will improve over time, as more of the ability of the model is exposed to the XFA world.

    Hope that helps

    Paul

  • SCHEMAVALIDATE() fails only in the oracle database.

    I have this function that performs a simple XML validation against a XSD upload in the database.


    [code]

    PROCEDURE do_xml_validation (xmlRequest IN XMLTYPE, xsdToValidate IN VARCHAR2, OUT VARCHAR2 returnStatus)

    IS

    lx_xmldoc XMLTYPE.

    BEGIN

    lx_xmldoc: = xmlRequest.createSchemaBasedXML (xsdToValidate);

    Start

    lx_xmldoc. SCHEMAVALIDATE();

    returnStatus: = STATUS_OK;

    EXCEPTION, THEN THAN OTHERS

    THEN

    dbms_output.put_line ('[do_xml_validation] = invalid XML = > ' |) SQLERRM);

    util.Comment ("[do_xml_validation] = invalid XML = > ' |") SQLERRM);

    returnStatus: = sqlerrm;

    END;

    END do_xml_validation;

    [/ code]

    Now... the XML and XSD below, validate correctly in xmltools for notepad ++, as well as in W3C web site:
    Validation W3C XML Schema (XSD) online

    It fails only in the database with this error:

    "ORA-31154: invalid XML document.

    ORA-19202: an error has occurred in the processing of XML

    ' LSX-00333: literal "dot1q 4090' is not valid with respect to the model.

    It is linked with the attribute 'encapsulationEnumeration '...

    Anyone with similar problems? I can't explain why this fails in Oracle only.

    XML is:

    < SSLI class = "FLOW_POINT" name = "dasfasfd" transaction = "crΘer" >

    <>attributes

    < name > sdfsafd < / name >

    < port_name > < / port_name >

    < encapsulation > dot1q 4090 < / encapsulation >

    < / attribute >

    < / SSLI >

    Download XSD in the database

    <? XML version = "1.0" encoding = "UTF-8"? >

    <!--

    XSD schema for the active catalog entry

    Seller: IOS_XE

    RFS: EthernetFlowPoint

    ->

    " < xs: schema xmlns: XS =" http://www.w3.org/2001/XMLSchema "elementFormDefault ="unqualified"> "

    <! - TYPE SIMPLE DEFINITIONS - >

    < xs:simpleType name = "encapsulationEnumeration" >

    < values basic memberTypes = "stringEnum dot1qString seconddot1qString" / >

    < / xs:simpleType >

    < xs:simpleType name = "stringEnum" >

    < xs:restriction base = "XS: String" >

    < xs:enumeration value = "default" / >

    < xs:enumeration value = "any" / >

    < xs:enumeration value = 'priority-tag' / >

    < xs:enumeration value = 'unidentified' / >

    < / xs:restriction >

    < / xs:simpleType >

    < xs:simpleType name = "dot1qString" >

    < xs:restriction base = "XS: String" >

    < value pattern = "dot1q\s ([1-9] |)" [0-9] [0-9] | [1-9] [0-9] [0-9] | ([1-3] [0-9] [0-9] [0-9]|40[0-8][0-9]|409[0-4]) "/ >

    < / xs:restriction >

    < / xs:simpleType >

    < xs:simpleType name = "seconddot1qString" >

    < xs:restriction base = "XS: String" >

    < value pattern = "dot1q\s ([1-9] |)" [0-9] [0-9] | [1-9] [0-9] [0-9] | [1-3] [0-9] [0-9] [0-9]|40[0-8][0-9]|409[0-4])\ssecond-dot1q\s ([1-9] |) [0-9] [0-9] | [1-9] [0-9] [0-9] | ([1-3] [0-9] [0-9] [0-9]|40[0-8][0-9]|409[0-4]) "/ >

    < / xs:restriction >

    < / xs:simpleType >

    <! - GROUPS DEFINITIONS - >

    < name XS: Group = "AttributesGroup" >

    < xs: SEQUENCE >

    < xs: element name = "name" type = "xs: String" minOccurs = "1" maxOccurs = "1" / >

    < xs: element name = "port_name" type = "xs: String" minOccurs = "0" maxOccurs = "1" / >

    < xs: element name = "encapsulation" type = "encapsulationEnumeration" minOccurs = "0" maxOccurs = "1" / >

    < / xs: SEQUENCE >

    < / xs: Group >

    <! - BASIC DEFINITIONS of COMPLEX TYPES - >

    < name XS: complexType 'SSLI' = >

    < xs: SEQUENCE >

    < xs: element name = "attributes" minOccurs = "1" maxOccurs = "unbounded" >

    < xs: complexType >

    < xs: Choice minOccurs = "1" maxOccurs = "unbounded" >

    < xs: Group ref = "AttributesGroup" / >

    < / xs: Choice >

    < / xs: complexType >

    < / xs: element >

    < / xs: SEQUENCE >

    < name XS: attribute = "class" type = "xs: String" use = "required" / >

    < name XS: attribute = "name" type = "xs: String" use = "required" / >

    < name XS: attribute = "transaction" type = "xs: String" use = "required" / >

    < / xs: complexType >

    <! - ROOT ELEMENT - >

    < xs: element name = "SSLI" type = "SSLI" / >

    < / xs: Schema >

    Anyone with similar problems? I can't explain why this fails in Oracle only.

    This is a bug.

    I can reproduce it on 12.1.0.2 too, even during the recording of binary XML schema.

    There have been some problems with validation of model for a while now pending, and they are not yet fixed.

    You must open a SR with Oracle's Support.

    BTW, in the future, to the right place for these issues would be the XML DB forum.

  • How to recover data from plsql table in the BI publisher data model

    Hi all

    I created a data model for XML editor report. In the data model I m get plsql table data. for this I created a package with a function in the pipeline. I am able to run sql in sql developer. But if I run the program at the same time, then I got error like "java.sql.SQLSyntaxErrorException: ORA-00904:"XXXXX": invalid identifier.

    I used the same settings in the data model and simultaneous program...

    Please tell me what to do...

    Thanks in advance...

    Kind regards
    Doss

    I think P_ORG_ID is the parameter
    so use

    :P_ORG_ID
    

    -Add
    also why not use simple sql query?

    Published by: Alexandr Sep 14, 2012 04:48

  • Comment of tables and columns are included in the Data Modeler

    Hi all
    I used Oracle SQL Developer Data Modeler (Version 3.0.0.665) and created a data model for my project. I sent an email a PDF version of the data model to our systems analyst. She asked if I could re - create the data model and include table and column comments. Is this possible and if so how this work is it?

    Thank you for your comments,

    Seyed

    Seyed salvation,

    I used the Data Modeler and create a report. The report included 36 .csv files

    What is the purpose of this 'report' task, because 36 files csv does not sound like report to me. Watch "files > reports" feature - you can generate reports for your model. -for any model, single table or tables belonging to specific subview. The report of the complete table contains additional details, so if you need these comments, then only you can create a template and select column comments appear only. So some general information table will be also included.

    Philippe

Maybe you are looking for

  • How can I get the status bar on my web page

    I want to get the status bar at the bottom of the web page so that I can slide from left to right, if an article is too large for my monitor. I got it this morning 05/01/15. After Thunderbird as an option for my email, the bar disappeared after unins

  • Application at startup

    I have an app "Steam" which opens every time at startup when the computer turns on, but I have found no disabling this option as there is on other applications, if anyone knows if there is another way to do it?

  • Contact does not iMac iPhone sync?

    larrybobba , December 1, 2015 20:07 I added a new contact in the Contacts app on my iMac. The new contact appears / synchronizations, as expected, to my iPad. However, it does not sync on my iPhone... I checked my settings and power rolled, nothing h

  • reverse in the lines in a 2D-string table

    Hello I have a simple question.but kind, I tried many things and could not help. I need to reverse a 2D channels in rows.just table to make it clear, I do an example: a, b and c d e f g h i and I want to do g h i d e f a, b and c How can I do this?

  • Photosmart C4780 "cannot find the wireless router.

    OK so apparently I'm not as tech savvy as I like to think of myself. I just got a used C4780 and spent 12 hours trying to figure how to set up so that I can print wireless. I had zero luck with that. I read that the WPS connection method is more easy