I am brand new to XML and XSD creation. I am in the very basic stages of trying to form validating schema. However, I have spent a lot of time going in circles on this. If someone could review and please give me a better understanding of what is happening with the code? It is saying there is no global declaration for the root reports.
The error code reads as
Cvc-elt.1.a: Cannot Find The Declaration Of Element 'xs:reports'., Line '1', Column '134'.
<?xml version="1.0" encoding="UTF-8"?>
<xs:reports xmlns:xs="https://www.w3schools.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="user.xsd">
user(
userID SERIAL,
username varchar(255),
password varchar(255),
firstname varchar(255),
middlename varchar(255),
lastname varchar(255),
email varchar(255),
dob date,
gender varchar(10)
profile_photo bytea,
home_phone varchar(50),
cell_phone varchar(50),
created_date timestamp default current_timestamp
);
</xs:reports>
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified">
<xs:element name="reports">
<xs:complexType>
<xs:sequence>
<xs:element name="user">
<xs:complexType>
<xs:sequence>
<xs:element name="userID" type="xs:string"/>
<xs:element name="username" type="xs:string"/>
<xs:element name="password" type="xs:string"/>
<xs:element name="firstname" type="xs:string"/>
<xs:element name="middlename" type="xs:string"/>
<xs:element name="lastname" type="xs:string"/>
<xs:element name="email" type="xs:string"/>
<xs:element name="dob" type="xs:date"/>
<xs:element name="gender" type="xs:string"/>
<xs:element name="profile_photo" type="xs:string"/>
<xs:element name="cell_phone" type="xs:string"/>
<xs:element name="created_date" type="xs:dateTime"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>